Files
deb-python-taskflow/taskflow/atom.py
Joshua Harlow 70e58977c9 Add atom priority ability
In situations where many atoms can execute at the same
time it is sometimes useful to denote that when this situation
happens that certain atoms should execute/revert before other
atoms (or at least an attempt should be made to do this) instead
of being nearly arbitrary.

This adds a priority class attribute to the atom class (which
can be overridden or changed as needed) which is then used in
the runtime state machine to sort on so that atoms with higher
priority get submitted (and therefore executed/reverted) first.

Closes-Bug: #1507755

Change-Id: I3dcc705959085cba167883c85278e394b5cb1d2b
2015-10-19 19:48:01 +00:00

12 KiB