Skip to main content

Fleet

Fleet is a generic distributed task distribution framework based on a distributed file system. Task distribution frameworks like Ray and Celery require network connections for communication, which makes them difficult to use in clusters with poor network conditions. Fleet is a distributed framework based on a shared file system, independent of any network communication, allowing for task distribution among nodes without any network connections.

Features

  • Distributed task distribution based on a shared file system
  • Supports dynamic scaling
  • Supports worker node heartbeat
  • Supports manager node restart
  • Supports set timeout for each task
  • Supports set max_job and max_work_time for worker
  • Pure Python implementation

Install

pip install open-fleet

Usage

See more examples in ./examples.

# run_manager.py
from fleet.manager import Manager
from fleet.config.config import get_args

base_dir = "./share_dir"

def main():
    job_list = [1,2,3,4]
    args = get_args(f"--base_dir {base_dir}")
    manager = Manager(args=args, job_list=job_list)
    manager.run()

if __name__ == '__main__':
    main()
# run_worker.py
from fleet.worker import Worker
from fleet.config.config import get_args

from run_manager import base_dir

def add_one(x, info):
    return {"status": "success", "result": x + 1}

def main():
    args = get_args(f"--base_dir {base_dir}")
    worker = Worker(args=args, job_func=add_one)
    worker.run()

if __name__ == '__main__':
    main()

Release files for open-fleet 0.0.7

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for open-fleet 0.0.7
File Size Uploaded
open_fleet-0.0.7.tar.gz 15.1 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for open-fleet 0.0.7
File Interpreter ABI Platform
open_fleet-0.0.7-py3-none-any.whl Python 3 none any Details

Total release size: 30.8 kB

Release files / open_fleet-0.0.7.tar.gz

Download URL open_fleet-0.0.7.tar.gz
Size 15.1 kB
Tags Source
SHA-256 checksum
How to use checksums
3c66ff6909c28bfa019eb16a1eda80553a7a49acfc9f47eaccacf26a9be65b6b
BLAKE2b-256 checksum
How to use checksums
f50a0528fcd722c02b1977a7024eebc76847090670514ec28184114c38e9120c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.0.0 CPython/3.9.6

Release files / open_fleet-0.0.7-py3-none-any.whl

Download URL open_fleet-0.0.7-py3-none-any.whl
Size 15.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
90598cfc90a38b1b306b11110fffec1f7e1b7f3b11473dfce2917fda68ddf002
BLAKE2b-256 checksum
How to use checksums
c89953b66b27e42cff9b1076a94108e978b31c431b3eb364bab7f8f5315f24ca
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/5.0.0 CPython/3.9.6

Release history Release notifications | RSS feed

This release

0.0.7 This release

2 release files

0.0.6

2 release files

0.0.5

2 release files

0.0.4

2 release files

0.0.3

2 release files

0.0.2

2 release files

0.0.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page