There a set of openstack api functions which starts background actions
and return preliminary results - like 'novaclient.create'. Those functions
requires periodically check results and handle timeouts/errors
(and often cleanup + restart help to fix an error).
Check/retry/cleanup code duplicated over a lot of core projects.
As examples - heat, tempest, rally, etc and definitely in many third-party
I propose to provide common higth-level API for such functions, which uses
'futures' (http://en.wikipedia.org/wiki/Futures_and_promises) as a way to
present background task.
Idea is to add to each background-task-starter function a complimentary
that returns 'future' object. E.g.
create_future = novaclient.servers.create_async(....)
vm = create_future.result()
This allows to unify(and optimize) monitoring cycles, retries, etc.
Please found complete BP at
Kostiantyn Danilov aka koder http://koder.ua
Principal software engineer, Mirantis
-------------- next part --------------
An HTML attachment was scrubbed...