Added intersphinx to Python

Added cluster class reference
This commit is contained in:
Ilan Steemers
2015-07-06 11:11:22 +02:00
parent 70ea211cfa
commit c8095cb699
2 changed files with 65 additions and 1 deletions
+61 -1
View File
@@ -132,4 +132,64 @@ Afterwards the sentinel waits for the monitor to empty the result queue before t
- Wait for monitor to stop
.. warning::
If you force the cluster to terminate before the stop procedure has completed, you can lose tasks and their results.
If you force the cluster to terminate before the stop procedure has completed, you can lose tasks and their results.
Reference
---------
.. py:class:: Cluster
.. py:method:: start
Spawns a cluster and then returns
.. py:method:: stop
Initiates :ref:`stop_procedure` and waits for it to finish.
.. py:method:: stat
returns a :class:`Stat` object with the current cluster status.
.. py:attribute:: pid
The cluster process id.
.. py:attribute:: host
The current hostname
.. py:attribute:: sentinel
returns the :class:`multiprocessing.Process` containing the :class:`Sentinel`.
.. py:attribute:: timeout
The clusters timeout setting in seconds
.. py:attribute:: start_event
A :class:`multiprocessing.Event` indicating if the :class:`Sentinel` has finished starting the cluster
.. py:attribute:: stop_event
A :class:`multiprocessing.Event` used to instruct the :class:`Sentinel` to initiate the :ref:`stop_procedure`
.. py:attribute:: is_starting
Bool indicating if the cluster is busy starting up
.. py:attribute:: is_running
Bool. Tells you if the cluster is up and running.
.. py:attribute:: is_stopping
Bool. Shows that the stop procedure has been started.
.. py:attribute:: has_stopped
Bool. Tells you if the cluster finished the stop procedure
+4
View File
@@ -38,8 +38,12 @@ os.environ['DJANGO_SETTINGS_MODULE'] = 'django_q.tests.settings'
extensions = [
'alabaster',
'sphinx.ext.todo',
'sphinx.ext.intersphinx',
# 'sphinx.ext.autodoc'
]
intersphinx_mapping = {'python': ('https://docs.python.org/3.4', None)}
# Add any paths that contain templates here, relative to this directory.
templates_path = ['_templates']