Skip to main content

Efficient execution of trees of dependent tasks

Project description

# Verkefni [![pipeline status](https://gitlab.com/OldIronHorse/verkefni/badges/master/pipeline.svg)](https://gitlab.com/OldIronHorse/verkefni/-/commits/master) [![coverage report](https://gitlab.com/OldIronHorse/verkefni/badges/master/coverage.svg)](https://gitlab.com/OldIronHorse/verkefni/-/commits/master)

Verkefni means task or tasks in Icelandic.

Experiments in distributed task execution.

# Installation

  1. clone the repo

  2. create and activate your virtual environment (Python 3.10)

  3. pip install -e .

  4. run a rabbitmq broker on localhost e.g. docker run -d –name rmq-broker -p 15672:15672 -p 5672:5672 rabbitmq:3-management-alpine

  5. configure (this sets up the exchanges: work and result)

# Usage

The rabbitmq host defaults to localhost.

This can be overriden by setting the RMQ_HOST environment variable.

## log EXCHANGE

This command logs all the messages send to the specified exchange.

log work

log result

Note: this script creates a persistent queue (log-_EXCHANGE_) which will continue to collect messages if the script is stoppped.

## worker-lexical

This is a worker process implementing word counting and sorting.

worker-lexical

## worker-arithmetic

This is a worker process implementing square and sum.

worker-arithmetic

## monitor QUEUE_NAME WORKER

This ia a _very_ simplistic auto scaling controller based on queue depth.

monitor arithmetic-1 worker-arithmetic

## tasker COUNT

This script launches a mixture of dependent and independent arithmetical and lexical tasks, captures the results and reports completion.

COUNT is the length of the list of numbers used in the arithmetical tasks.

tasker 10

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

verkefni-0.1.1.tar.gz (6.5 kB view details)

Uploaded Source

Built Distribution

verkefni-0.1.1-py3-none-any.whl (8.6 kB view details)

Uploaded Python 3

File details

Details for the file verkefni-0.1.1.tar.gz.

File metadata

  • Download URL: verkefni-0.1.1.tar.gz
  • Upload date:
  • Size: 6.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.5.0 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.10.0

File hashes

Hashes for verkefni-0.1.1.tar.gz
Algorithm Hash digest
SHA256 072e12492746b990ffb3bd7d2cd52512a5fe3891445d52e416baa001220ac7b1
MD5 3ff4f7479b835952c70242f82dfea8ba
BLAKE2b-256 78603df234c0318567b706e3675c07da8956ee5a657ffb14d7186fc4e6760554

See more details on using hashes here.

File details

Details for the file verkefni-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: verkefni-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 8.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.5.0 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.10.0

File hashes

Hashes for verkefni-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 7eebd771c99c0996b08ee653f65f327c949a8c84130d0bcdb446686ff77c1d4f
MD5 5a6481e920eeddf2fa3e9328a10668cc
BLAKE2b-256 0ad263c0ca04797079faa76f50188925e93416a5ed0d58d48c8972f8543dc5d8

See more details on using hashes here.

Supported by

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