A library to complete workflows/tasks in HA manner
Go to file
Joshua Harlow cea71f2799 Fix for WBE sporadic timeout of tasks
This fixes the sporadic of tasks that would happen
under certain circumstances. What happened was that
a new worker notification would be sent to a callback
while at the same time a task submission would come in
and there would be a small race period where the task
would insert itself into the requests cache while the
callback was processing.

So to work around this the whole concept of a requests
cache was revamped and now the WBE executor just maintains
its own local dictionary of ongoing requests and accesses
it safely.

During the on_wait function that is periodically called
by kombu the previous expiry of work happens but now any
requests that are pending are matched to any new workers
that may have appeared.

This avoids the race (and ensures that even if a new
worker is found but a submission is in progress that the
duration until that submission happens will only be until
the next on_wait call happens).

Related-Bug: #1431097

Change-Id: I98b0caeedc77ab2f7214847763ae1eb0433d4a78
2016-02-05 14:40:25 -08:00
doc Fix for WBE sporadic timeout of tasks 2016-02-05 14:40:25 -08:00
taskflow Fix for WBE sporadic timeout of tasks 2016-02-05 14:40:25 -08:00
tools Use automaton's converters/pydot 2015-10-11 01:11:29 +00:00
.coveragerc Change ignore-errors to ignore_errors 2015-09-21 14:55:59 +00:00
.gitignore Fix the sphinx build path in .gitignore file 2015-09-22 22:44:33 +05:30
.gitreview Update .gitreview after repo rename 2014-02-07 20:45:32 +00:00
.mailmap Remap the emails of the committers 2013-09-17 13:27:27 -07:00
.testr.conf Enable OS_LOG_CAPTURE so that logs can be seen (on error) 2016-01-28 14:26:24 -08:00
CONTRIBUTING.rst Workflow documentation is now in infra-manual 2014-12-05 03:30:41 +00:00
LICENSE Move the code over for now 2013-05-07 10:49:44 -07:00
README.rst Remove reference to 'requirements-pyN.txt' files 2015-06-20 09:11:58 -07:00
pylintrc Fix a couple of spelling and grammar errors 2015-03-29 03:11:08 +11:00
requirements.txt Updated from global requirements 2016-01-23 10:54:38 +00:00
run_tests.sh Switch to just using tox 2014-01-02 10:38:15 -08:00
setup.cfg Add a executor backed conductor and have existing impl. use it 2015-11-12 17:03:00 -08:00
setup.py Updated from global requirements 2015-09-18 16:43:06 +00:00
test-requirements.txt Updated from global requirements 2016-01-24 20:55:00 +00:00
tox.ini Deprecated tox -downloadcache option removed 2015-12-11 23:39:27 +01:00

README.rst

TaskFlow

Latest Version

Downloads

A library to do [jobs, tasks, flows] in a highly available, easy to understand and declarative manner (and more!) to be used with OpenStack and other projects.

Join us

Testing and requirements

Requirements

Because this project has many optional (pluggable) parts like persistence backends and engines, we decided to split our requirements into two parts: - things that are absolutely required (you can't use the project without them) are put into requirements.txt. The requirements that are required by some optional part of this project (you can use the project without them) are put into our test-requirements.txt file (so that we can still test the optional functionality works as expected). If you want to use the feature in question (eventlet or the worker based engine that uses kombu or the sqlalchemy persistence backend or jobboards which have an implementation built using kazoo ...), you should add that requirement(s) to your project or environment.

Tox.ini

Our tox.ini file describes several test environments that allow to test TaskFlow with different python versions and sets of requirements installed. Please refer to the tox documentation to understand how to make these test environments work for you.

Developer documentation

We also have sphinx documentation in docs/source.

To build it, run:

$ python setup.py build_sphinx