Skip to main content

Asynchronous and distributed scheduling of Ewoks workflows from python

Project description

ewoksjob

Utilities for job scheduling of ewoks workflows.

Ewoksjob provides an ewoks interface for asynchronous and distributed scheduling of ewoks from python.

Note that ewoksjob distributes the execution of workflows while ewoksdask distributes the execution of tasks in a workflow. So in the context of workflows, job scheduling exists on two levels.

The primary clients that need to schedule workflows are

Installation

Install on the client side

pip install ewoksjob

Install on the worker side

pip install ewoksjob[worker]

Getting started

Start a worker pool that can execute ewoks graphs

celery -A ewoksjob.apps.ewoks worker

Start a workflow on the client side

from ewoksjob.client import submit

workflow = {"graph": {"id": "mygraph"}}
future = submit(args=(workflow,))
result = future.get()

Note that both environments need to be able to import celeryconfig which contains celery configuration (mainly the message broker and result backend URL's).

Hello world example

Clone the git repository and start a worker pool

./examples/worker.sh

Submit the hello world workflow

python examples/helloworld.py

Tests

python3 -m pytest --pyargs ewoksjob

To run the redis tests you need redis-server (e.g. conda install redis-server).

Documentation

https://ewoksjob.readthedocs.io/

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ewoksjob-0.0.10rc1.tar.gz (18.1 kB view details)

Uploaded Source

File details

Details for the file ewoksjob-0.0.10rc1.tar.gz.

File metadata

  • Download URL: ewoksjob-0.0.10rc1.tar.gz
  • Upload date:
  • Size: 18.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.5

File hashes

Hashes for ewoksjob-0.0.10rc1.tar.gz
Algorithm Hash digest
SHA256 58d1a9c10d7d620dba9b45b77bd4e21e79555e67c62395565a5937a0e83d9c48
MD5 25dbf6f8fa128cb9d6ec6b77d6e1ef44
BLAKE2b-256 61ddac10619bf01dd610210f2677190321b685544fc9eb2c68808f4cfa6d9723

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page