Merge "Cleanup some doc warnings/bad/broken links"
This commit is contained in:
@@ -167,7 +167,7 @@ Additional supported keyword arguments:
|
|||||||
* ``executor``: a object that implements a :pep:`3148` compatible `executor`_
|
* ``executor``: a object that implements a :pep:`3148` compatible `executor`_
|
||||||
interface; it will be used for scheduling tasks. You can use instances of a
|
interface; it will be used for scheduling tasks. You can use instances of a
|
||||||
`thread pool executor`_ or a :py:class:`green executor
|
`thread pool executor`_ or a :py:class:`green executor
|
||||||
<taskflow.utils.eventlet_utils.GreenExecutor>` (which internally uses
|
<taskflow.types.futures.GreenThreadPoolExecutor>` (which internally uses
|
||||||
`eventlet <http://eventlet.net/>`_ and greenthread pools).
|
`eventlet <http://eventlet.net/>`_ and greenthread pools).
|
||||||
|
|
||||||
.. tip::
|
.. tip::
|
||||||
@@ -271,13 +271,13 @@ Scheduling
|
|||||||
^^^^^^^^^^
|
^^^^^^^^^^
|
||||||
|
|
||||||
This stage selects which atoms are eligible to run by using a
|
This stage selects which atoms are eligible to run by using a
|
||||||
:py:class:`~taskflow.engines.action_engine.runtime.Scheduler` implementation
|
:py:class:`~taskflow.engines.action_engine.scheduler.Scheduler` implementation
|
||||||
(the default implementation looks at there intention, checking if predecessor
|
(the default implementation looks at there intention, checking if predecessor
|
||||||
atoms have ran and so-on, using a
|
atoms have ran and so-on, using a
|
||||||
:py:class:`~taskflow.engines.action_engine.analyzer.Analyzer` helper
|
:py:class:`~taskflow.engines.action_engine.analyzer.Analyzer` helper
|
||||||
object as needed) and submits those atoms to a previously provided compatible
|
object as needed) and submits those atoms to a previously provided compatible
|
||||||
`executor`_ for asynchronous execution. This
|
`executor`_ for asynchronous execution. This
|
||||||
:py:class:`~taskflow.engines.action_engine.runtime.Scheduler` will return a
|
:py:class:`~taskflow.engines.action_engine.scheduler.Scheduler` will return a
|
||||||
`future`_ object for each atom scheduled; all of which are collected into a
|
`future`_ object for each atom scheduled; all of which are collected into a
|
||||||
list of not done futures. This will end the initial round of scheduling and at
|
list of not done futures. This will end the initial round of scheduling and at
|
||||||
this point the engine enters the :ref:`waiting <waiting>` stage.
|
this point the engine enters the :ref:`waiting <waiting>` stage.
|
||||||
@@ -290,7 +290,7 @@ Waiting
|
|||||||
In this stage the engine waits for any of the future objects previously
|
In this stage the engine waits for any of the future objects previously
|
||||||
submitted to complete. Once one of the future objects completes (or fails) that
|
submitted to complete. Once one of the future objects completes (or fails) that
|
||||||
atoms result will be examined and finalized using a
|
atoms result will be examined and finalized using a
|
||||||
:py:class:`~taskflow.engines.action_engine.runtime.Completer` implementation.
|
:py:class:`~taskflow.engines.action_engine.completer.Completer` implementation.
|
||||||
It typically will persist results to a provided persistence backend (saved
|
It typically will persist results to a provided persistence backend (saved
|
||||||
into the corresponding :py:class:`~taskflow.persistence.logbook.AtomDetail`
|
into the corresponding :py:class:`~taskflow.persistence.logbook.AtomDetail`
|
||||||
and :py:class:`~taskflow.persistence.logbook.FlowDetail` objects) and reflect
|
and :py:class:`~taskflow.persistence.logbook.FlowDetail` objects) and reflect
|
||||||
@@ -330,18 +330,21 @@ Interfaces
|
|||||||
|
|
||||||
.. automodule:: taskflow.engines.action_engine.analyzer
|
.. automodule:: taskflow.engines.action_engine.analyzer
|
||||||
.. automodule:: taskflow.engines.action_engine.compiler
|
.. automodule:: taskflow.engines.action_engine.compiler
|
||||||
|
.. automodule:: taskflow.engines.action_engine.completer
|
||||||
.. automodule:: taskflow.engines.action_engine.engine
|
.. automodule:: taskflow.engines.action_engine.engine
|
||||||
.. automodule:: taskflow.engines.action_engine.runner
|
.. automodule:: taskflow.engines.action_engine.runner
|
||||||
.. automodule:: taskflow.engines.action_engine.runtime
|
.. automodule:: taskflow.engines.action_engine.runtime
|
||||||
|
.. automodule:: taskflow.engines.action_engine.scheduler
|
||||||
|
.. automodule:: taskflow.engines.action_engine.scopes
|
||||||
.. automodule:: taskflow.engines.base
|
.. automodule:: taskflow.engines.base
|
||||||
|
|
||||||
Hierarchy
|
Hierarchy
|
||||||
=========
|
=========
|
||||||
|
|
||||||
.. inheritance-diagram::
|
.. inheritance-diagram::
|
||||||
taskflow.engines.base
|
taskflow.engines.action_engine.engine.ActionEngine
|
||||||
taskflow.engines.action_engine.engine
|
taskflow.engines.base.Engine
|
||||||
taskflow.engines.worker_based.engine
|
taskflow.engines.worker_based.engine.WorkerBasedActionEngine
|
||||||
:parts: 1
|
:parts: 1
|
||||||
|
|
||||||
.. _future: https://docs.python.org/dev/library/concurrent.futures.html#future-objects
|
.. _future: https://docs.python.org/dev/library/concurrent.futures.html#future-objects
|
||||||
|
|||||||
@@ -17,10 +17,9 @@ transitions, which is useful for monitoring, logging, metrics, debugging
|
|||||||
and plenty of other tasks.
|
and plenty of other tasks.
|
||||||
|
|
||||||
To receive these notifications you should register a callback with
|
To receive these notifications you should register a callback with
|
||||||
an instance of the :py:class:`~taskflow.utils.misc.Notifier`
|
an instance of the :py:class:`~taskflow.types.notifier.Notifier`
|
||||||
class that is attached
|
class that is attached to :py:class:`~taskflow.engines.base.Engine`
|
||||||
to :py:class:`Engine <taskflow.engines.base.EngineBase>`
|
attributes ``atom_notifier`` and ``notifier``.
|
||||||
attributes ``task_notifier`` and ``notifier``.
|
|
||||||
|
|
||||||
TaskFlow also comes with a set of predefined :ref:`listeners <listeners>`, and
|
TaskFlow also comes with a set of predefined :ref:`listeners <listeners>`, and
|
||||||
provides means to write your own listeners, which can be more convenient than
|
provides means to write your own listeners, which can be more convenient than
|
||||||
@@ -34,7 +33,7 @@ Flow notifications
|
|||||||
------------------
|
------------------
|
||||||
|
|
||||||
To receive notification on flow state changes use the
|
To receive notification on flow state changes use the
|
||||||
:py:class:`~taskflow.utils.misc.Notifier` instance available as the
|
:py:class:`~taskflow.types.notifier.Notifier` instance available as the
|
||||||
``notifier`` property of an engine.
|
``notifier`` property of an engine.
|
||||||
|
|
||||||
A basic example is:
|
A basic example is:
|
||||||
@@ -69,8 +68,8 @@ Task notifications
|
|||||||
------------------
|
------------------
|
||||||
|
|
||||||
To receive notification on task state changes use the
|
To receive notification on task state changes use the
|
||||||
:py:class:`~taskflow.utils.misc.Notifier` instance available as the
|
:py:class:`~taskflow.types.notifier.Notifier` instance available as the
|
||||||
``task_notifier`` property of an engine.
|
``atom_notifier`` property of an engine.
|
||||||
|
|
||||||
A basic example is:
|
A basic example is:
|
||||||
|
|
||||||
@@ -149,12 +148,12 @@ For example, this is how you can use
|
|||||||
Basic listener
|
Basic listener
|
||||||
--------------
|
--------------
|
||||||
|
|
||||||
.. autoclass:: taskflow.listeners.base.ListenerBase
|
.. autoclass:: taskflow.listeners.base.Listener
|
||||||
|
|
||||||
Printing and logging listeners
|
Printing and logging listeners
|
||||||
------------------------------
|
------------------------------
|
||||||
|
|
||||||
.. autoclass:: taskflow.listeners.base.LoggingBase
|
.. autoclass:: taskflow.listeners.base.DumpingListener
|
||||||
|
|
||||||
.. autoclass:: taskflow.listeners.logging.LoggingListener
|
.. autoclass:: taskflow.listeners.logging.LoggingListener
|
||||||
|
|
||||||
@@ -173,3 +172,17 @@ Claim listener
|
|||||||
--------------
|
--------------
|
||||||
|
|
||||||
.. autoclass:: taskflow.listeners.claims.CheckingClaimListener
|
.. autoclass:: taskflow.listeners.claims.CheckingClaimListener
|
||||||
|
|
||||||
|
Hierarchy
|
||||||
|
---------
|
||||||
|
|
||||||
|
.. inheritance-diagram::
|
||||||
|
taskflow.listeners.base.DumpingListener
|
||||||
|
taskflow.listeners.base.Listener
|
||||||
|
taskflow.listeners.claims.CheckingClaimListener
|
||||||
|
taskflow.listeners.logging.DynamicLoggingListener
|
||||||
|
taskflow.listeners.logging.LoggingListener
|
||||||
|
taskflow.listeners.printing.PrintingListener
|
||||||
|
taskflow.listeners.timing.PrintingTimingListener
|
||||||
|
taskflow.listeners.timing.TimingListener
|
||||||
|
:parts: 1
|
||||||
|
|||||||
@@ -230,7 +230,7 @@ def _get_arg_spec(function):
|
|||||||
def get_callable_args(function, required_only=False):
|
def get_callable_args(function, required_only=False):
|
||||||
"""Get names of callable arguments.
|
"""Get names of callable arguments.
|
||||||
|
|
||||||
Special arguments (like *args and **kwargs) are not included into
|
Special arguments (like ``*args`` and ``**kwargs``) are not included into
|
||||||
output.
|
output.
|
||||||
|
|
||||||
If required_only is True, optional arguments (with default values)
|
If required_only is True, optional arguments (with default values)
|
||||||
|
|||||||
Reference in New Issue
Block a user