celery.conf.html 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308
  1. <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
  2. "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  3. <html xmlns="http://www.w3.org/1999/xhtml">
  4. <head>
  5. <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
  6. <title>Configuration - celery.conf &mdash; Celery v0.7.0 (unstable) documentation</title>
  7. <link rel="stylesheet" href="../static/nature.css" type="text/css" />
  8. <link rel="stylesheet" href="../static/pygments.css" type="text/css" />
  9. <script type="text/javascript">
  10. var DOCUMENTATION_OPTIONS = {
  11. URL_ROOT: '../',
  12. VERSION: '0.7.0 (unstable)',
  13. COLLAPSE_MODINDEX: false,
  14. FILE_SUFFIX: '.html',
  15. HAS_SOURCE: true
  16. };
  17. </script>
  18. <script type="text/javascript" src="../static/jquery.js"></script>
  19. <script type="text/javascript" src="../static/doctools.js"></script>
  20. <link rel="top" title="Celery v0.7.0 (unstable) documentation" href="../index.html" />
  21. <link rel="up" title="Module API Reference" href="index.html" />
  22. <link rel="next" title="Datastructures - celery.datastructures" href="celery.datastructures.html" />
  23. <link rel="prev" title="Backend: Tokyo Tyrant - celery.backends.tyrant" href="celery.backends.tyrant.html" />
  24. </head>
  25. <body>
  26. <div class="related">
  27. <h3>Navigation</h3>
  28. <ul>
  29. <li class="right" style="margin-right: 10px">
  30. <a href="../genindex.html" title="General Index"
  31. accesskey="I">index</a></li>
  32. <li class="right" >
  33. <a href="../modindex.html" title="Global Module Index"
  34. accesskey="M">modules</a> |</li>
  35. <li class="right" >
  36. <a href="celery.datastructures.html" title="Datastructures - celery.datastructures"
  37. accesskey="N">next</a> |</li>
  38. <li class="right" >
  39. <a href="celery.backends.tyrant.html" title="Backend: Tokyo Tyrant - celery.backends.tyrant"
  40. accesskey="P">previous</a> |</li>
  41. <li><a href="../index.html">Celery v0.7.0 (unstable) documentation</a> &raquo;</li>
  42. <li><a href="index.html" accesskey="U">Module API Reference</a> &raquo;</li>
  43. </ul>
  44. </div>
  45. <div class="document">
  46. <div class="documentwrapper">
  47. <div class="bodywrapper">
  48. <div class="body">
  49. <div class="section" id="module-celery.conf">
  50. <h1>Configuration - celery.conf<a class="headerlink" href="#module-celery.conf" title="Permalink to this headline">¶</a></h1>
  51. <p>celery.conf</p>
  52. <dl class="data">
  53. <dt id="celery.conf.ALWAYS_EAGER">
  54. <tt class="descclassname">celery.conf.</tt><tt class="descname">ALWAYS_EAGER</tt><a class="headerlink" href="#celery.conf.ALWAYS_EAGER" title="Permalink to this definition">¶</a></dt>
  55. <dd></dd></dl>
  56. <dl class="data">
  57. <dt id="celery.conf.AMQP_CONNECTION_RETRY">
  58. <tt class="descclassname">celery.conf.</tt><tt class="descname">AMQP_CONNECTION_RETRY</tt><a class="headerlink" href="#celery.conf.AMQP_CONNECTION_RETRY" title="Permalink to this definition">¶</a></dt>
  59. <dd><dl class="data">
  60. <dt id="celery.conf.AMQP_CONNECTION_MAX_RETRIES">
  61. <tt class="descclassname">celery.conf.</tt><tt class="descname">AMQP_CONNECTION_MAX_RETRIES</tt><a class="headerlink" href="#celery.conf.AMQP_CONNECTION_MAX_RETRIES" title="Permalink to this definition">¶</a></dt>
  62. <dd></dd></dl>
  63. <p>Maximum number of retries before we give up re-establishing a connection
  64. to the AMQP broker.</p>
  65. <p>If this is set to <tt class="docutils literal"><span class="pre">0</span></tt> or <tt class="xref docutils literal"><span class="pre">None</span></tt>, we will retry forever.</p>
  66. <p>Default is <tt class="docutils literal"><span class="pre">100</span></tt> retries.</p>
  67. </dd></dl>
  68. <dl class="data">
  69. <dt id="celery.conf.AMQP_CONNECTION_TIMEOUT">
  70. <tt class="descclassname">celery.conf.</tt><tt class="descname">AMQP_CONNECTION_TIMEOUT</tt><a class="headerlink" href="#celery.conf.AMQP_CONNECTION_TIMEOUT" title="Permalink to this definition">¶</a></dt>
  71. <dd><dl class="data">
  72. <dt id="celery.conf.SEND_CELERY_TASK_ERROR_EMAILS">
  73. <tt class="descclassname">celery.conf.</tt><tt class="descname">SEND_CELERY_TASK_ERROR_EMAILS</tt><a class="headerlink" href="#celery.conf.SEND_CELERY_TASK_ERROR_EMAILS" title="Permalink to this definition">¶</a></dt>
  74. <dd>If set to <tt class="xref docutils literal"><span class="pre">True</span></tt>, errors in tasks will be sent to admins by e-mail.
  75. If unset, it will send the e-mails if <tt class="docutils literal"><span class="pre">settings.DEBUG</span></tt> is False.</dd></dl>
  76. </dd></dl>
  77. <dl class="data">
  78. <dt id="celery.conf.AMQP_CONSUMER_QUEUE">
  79. <tt class="descclassname">celery.conf.</tt><tt class="descname">AMQP_CONSUMER_QUEUE</tt><a class="headerlink" href="#celery.conf.AMQP_CONSUMER_QUEUE" title="Permalink to this definition">¶</a></dt>
  80. <dd><dl class="data">
  81. <dt id="celery.conf.AMQP_CONSUMER_QUEUES">
  82. <tt class="descclassname">celery.conf.</tt><tt class="descname">AMQP_CONSUMER_QUEUES</tt><a class="headerlink" href="#celery.conf.AMQP_CONSUMER_QUEUES" title="Permalink to this definition">¶</a></dt>
  83. <dd>Dictionary defining multiple AMQP queues.</dd></dl>
  84. </dd></dl>
  85. <dl class="data">
  86. <dt>
  87. <tt class="descclassname">celery.conf.</tt><tt class="descname">AMQP_CONSUMER_QUEUES</tt></dt>
  88. <dd><dl class="data">
  89. <dt>
  90. <tt class="descclassname">celery.conf.</tt><tt class="descname">AMQP_CONNECTION_TIMEOUT</tt></dt>
  91. <dd>The timeout in seconds before we give up establishing a connection
  92. to the AMQP server.</dd></dl>
  93. </dd></dl>
  94. <dl class="data">
  95. <dt id="celery.conf.AMQP_CONSUMER_ROUTING_KEY">
  96. <tt class="descclassname">celery.conf.</tt><tt class="descname">AMQP_CONSUMER_ROUTING_KEY</tt><a class="headerlink" href="#celery.conf.AMQP_CONSUMER_ROUTING_KEY" title="Permalink to this definition">¶</a></dt>
  97. <dd><dl class="data">
  98. <dt>
  99. <tt class="descclassname">celery.conf.</tt><tt class="descname">AMQP_CONSUMER_QUEUE</tt></dt>
  100. <dd>The name of the AMQP queue.</dd></dl>
  101. </dd></dl>
  102. <dl class="data">
  103. <dt id="celery.conf.AMQP_EXCHANGE">
  104. <tt class="descclassname">celery.conf.</tt><tt class="descname">AMQP_EXCHANGE</tt><a class="headerlink" href="#celery.conf.AMQP_EXCHANGE" title="Permalink to this definition">¶</a></dt>
  105. <dd><dl class="data">
  106. <dt id="celery.conf.AMQP_EXCHANGE_TYPE">
  107. <tt class="descclassname">celery.conf.</tt><tt class="descname">AMQP_EXCHANGE_TYPE</tt><a class="headerlink" href="#celery.conf.AMQP_EXCHANGE_TYPE" title="Permalink to this definition">¶</a></dt>
  108. <dd></dd></dl>
  109. <p>The type of exchange. If the exchange type is <tt class="docutils literal"><span class="pre">direct</span></tt>, all messages
  110. receives all tasks. However, if the exchange type is <tt class="docutils literal"><span class="pre">topic</span></tt>, you can
  111. route e.g. some tasks to one server, and others to the rest.
  112. See <a class="reference external" href="http://bit.ly/wpamqpexchanges">Exchange types and the effect of bindings</a>.</p>
  113. </dd></dl>
  114. <dl class="data">
  115. <dt>
  116. <tt class="descclassname">celery.conf.</tt><tt class="descname">AMQP_EXCHANGE_TYPE</tt></dt>
  117. <dd><dl class="data">
  118. <dt id="celery.conf.AMQP_PUBLISHER_ROUTING_KEY">
  119. <tt class="descclassname">celery.conf.</tt><tt class="descname">AMQP_PUBLISHER_ROUTING_KEY</tt><a class="headerlink" href="#celery.conf.AMQP_PUBLISHER_ROUTING_KEY" title="Permalink to this definition">¶</a></dt>
  120. <dd>The default AMQP routing key used when publishing tasks.</dd></dl>
  121. </dd></dl>
  122. <dl class="data">
  123. <dt>
  124. <tt class="descclassname">celery.conf.</tt><tt class="descname">AMQP_PUBLISHER_ROUTING_KEY</tt></dt>
  125. <dd><dl class="data">
  126. <dt>
  127. <tt class="descclassname">celery.conf.</tt><tt class="descname">AMQP_CONSUMER_ROUTING_KEY</tt></dt>
  128. <dd>The AMQP routing key used when consuming tasks.</dd></dl>
  129. </dd></dl>
  130. <dl class="data">
  131. <dt id="celery.conf.DAEMON_CONCURRENCY">
  132. <tt class="descclassname">celery.conf.</tt><tt class="descname">DAEMON_CONCURRENCY</tt><a class="headerlink" href="#celery.conf.DAEMON_CONCURRENCY" title="Permalink to this definition">¶</a></dt>
  133. <dd><dl class="data">
  134. <dt>
  135. <tt class="descclassname">celery.conf.</tt><tt class="descname">AMQP_EXCHANGE</tt></dt>
  136. <dd>Name of the AMQP exchange.</dd></dl>
  137. </dd></dl>
  138. <dl class="data">
  139. <dt id="celery.conf.DAEMON_LOG_FILE">
  140. <tt class="descclassname">celery.conf.</tt><tt class="descname">DAEMON_LOG_FILE</tt><a class="headerlink" href="#celery.conf.DAEMON_LOG_FILE" title="Permalink to this definition">¶</a></dt>
  141. <dd><dl class="data">
  142. <dt id="celery.conf.DAEMON_LOG_LEVEL">
  143. <tt class="descclassname">celery.conf.</tt><tt class="descname">DAEMON_LOG_LEVEL</tt><a class="headerlink" href="#celery.conf.DAEMON_LOG_LEVEL" title="Permalink to this definition">¶</a></dt>
  144. <dd>Celery daemon log level, can be any of <tt class="docutils literal"><span class="pre">DEBUG</span></tt>, <tt class="docutils literal"><span class="pre">INFO</span></tt>, <tt class="docutils literal"><span class="pre">WARNING</span></tt>,
  145. <tt class="docutils literal"><span class="pre">ERROR</span></tt>, <tt class="docutils literal"><span class="pre">CRITICAL</span></tt>, or <tt class="docutils literal"><span class="pre">FATAL</span></tt>. See the <tt class="xref docutils literal"><span class="pre">logging</span></tt> module
  146. for more information.</dd></dl>
  147. </dd></dl>
  148. <dl class="data">
  149. <dt>
  150. <tt class="descclassname">celery.conf.</tt><tt class="descname">DAEMON_LOG_LEVEL</tt></dt>
  151. <dd><dl class="data">
  152. <dt id="celery.conf.DAEMON_PID_FILE">
  153. <tt class="descclassname">celery.conf.</tt><tt class="descname">DAEMON_PID_FILE</tt><a class="headerlink" href="#celery.conf.DAEMON_PID_FILE" title="Permalink to this definition">¶</a></dt>
  154. <dd>Full path to the daemon pidfile.</dd></dl>
  155. </dd></dl>
  156. <dl class="data">
  157. <dt>
  158. <tt class="descclassname">celery.conf.</tt><tt class="descname">DAEMON_PID_FILE</tt></dt>
  159. <dd><dl class="data">
  160. <dt>
  161. <tt class="descclassname">celery.conf.</tt><tt class="descname">DAEMON_CONCURRENCY</tt></dt>
  162. <dd>The number of concurrent worker processes, executing tasks simultaneously.</dd></dl>
  163. </dd></dl>
  164. <dl class="data">
  165. <dt id="celery.conf.DEFAULT_AMQP_CONNECTION_MAX_RETRIES">
  166. <tt class="descclassname">celery.conf.</tt><tt class="descname">DEFAULT_AMQP_CONNECTION_MAX_RETRIES</tt><a class="headerlink" href="#celery.conf.DEFAULT_AMQP_CONNECTION_MAX_RETRIES" title="Permalink to this definition">¶</a></dt>
  167. <dd><dl class="data">
  168. <dt id="celery.conf.LOG_LEVELS">
  169. <tt class="descclassname">celery.conf.</tt><tt class="descname">LOG_LEVELS</tt><a class="headerlink" href="#celery.conf.LOG_LEVELS" title="Permalink to this definition">¶</a></dt>
  170. <dd>Mapping of log level names to <tt class="xref docutils literal"><span class="pre">logging</span></tt> module constants.</dd></dl>
  171. </dd></dl>
  172. <dl class="data">
  173. <dt id="celery.conf.LOG_FORMAT">
  174. <tt class="descclassname">celery.conf.</tt><tt class="descname">LOG_FORMAT</tt><a class="headerlink" href="#celery.conf.LOG_FORMAT" title="Permalink to this definition">¶</a></dt>
  175. <dd><dl class="data">
  176. <dt>
  177. <tt class="descclassname">celery.conf.</tt><tt class="descname">DAEMON_LOG_FILE</tt></dt>
  178. <dd>The path to the deamon log file (if not set, <tt class="docutils literal"><span class="pre">stderr</span></tt> is used).</dd></dl>
  179. </dd></dl>
  180. <dl class="data">
  181. <dt>
  182. <tt class="descclassname">celery.conf.</tt><tt class="descname">LOG_LEVELS</tt></dt>
  183. <dd><dl class="data">
  184. <dt>
  185. <tt class="descclassname">celery.conf.</tt><tt class="descname">LOG_FORMAT</tt></dt>
  186. <dd>The format to use for log messages.
  187. Default is <tt class="docutils literal"><span class="pre">[%(asctime)s:</span> <span class="pre">%(levelname)s/%(processName)s]</span> <span class="pre">%(message)s</span></tt></dd></dl>
  188. </dd></dl>
  189. <dl class="data">
  190. <dt>
  191. <tt class="descclassname">celery.conf.</tt><tt class="descname">SEND_CELERY_TASK_ERROR_EMAILS</tt></dt>
  192. <dd><dl class="data">
  193. <dt id="celery.conf.STATISTICS_COLLECT_INTERVAL">
  194. <tt class="descclassname">celery.conf.</tt><tt class="descname">STATISTICS_COLLECT_INTERVAL</tt><a class="headerlink" href="#celery.conf.STATISTICS_COLLECT_INTERVAL" title="Permalink to this definition">¶</a></dt>
  195. <dd>The interval in seconds of which the
  196. <tt class="xref docutils literal"><span class="pre">celery.task.CollectStatisticsTask`</span></tt> is run.</dd></dl>
  197. </dd></dl>
  198. <dl class="data">
  199. <dt>
  200. <tt class="descclassname">celery.conf.</tt><tt class="descname">STATISTICS_COLLECT_INTERVAL</tt></dt>
  201. <dd><dl class="data">
  202. <dt>
  203. <tt class="descclassname">celery.conf.</tt><tt class="descname">ALWAYS_EAGER</tt></dt>
  204. <dd>If this is <tt class="xref docutils literal"><span class="pre">True</span></tt>, all tasks will be executed locally by blocking
  205. until it is finished. <tt class="docutils literal"><span class="pre">apply_async</span></tt> and <tt class="docutils literal"><span class="pre">delay_task</span></tt> will return
  206. a <a title="celery.result.EagerResult" class="reference external" href="celery.result.html#celery.result.EagerResult"><tt class="xref docutils literal"><span class="pre">celery.result.EagerResult</span></tt></a> which emulates the behaviour of
  207. an <a title="celery.result.AsyncResult" class="reference external" href="celery.result.html#celery.result.AsyncResult"><tt class="xref docutils literal"><span class="pre">celery.result.AsyncResult</span></tt></a>.</dd></dl>
  208. </dd></dl>
  209. </div>
  210. </div>
  211. </div>
  212. </div>
  213. <div class="sphinxsidebar">
  214. <div class="sphinxsidebarwrapper">
  215. <h4>Previous topic</h4>
  216. <p class="topless"><a href="celery.backends.tyrant.html"
  217. title="previous chapter">Backend: Tokyo Tyrant - celery.backends.tyrant</a></p>
  218. <h4>Next topic</h4>
  219. <p class="topless"><a href="celery.datastructures.html"
  220. title="next chapter">Datastructures - celery.datastructures</a></p>
  221. <h3>This Page</h3>
  222. <ul class="this-page-menu">
  223. <li><a href="../sources/reference/celery.conf.txt"
  224. rel="nofollow">Show Source</a></li>
  225. </ul>
  226. <div id="searchbox" style="display: none">
  227. <h3>Quick search</h3>
  228. <form class="search" action="../search.html" method="get">
  229. <input type="text" name="q" size="18" />
  230. <input type="submit" value="Go" />
  231. <input type="hidden" name="check_keywords" value="yes" />
  232. <input type="hidden" name="area" value="default" />
  233. </form>
  234. <p class="searchtip" style="font-size: 90%">
  235. Enter search terms or a module, class or function name.
  236. </p>
  237. </div>
  238. <script type="text/javascript">$('#searchbox').show(0);</script>
  239. </div>
  240. </div>
  241. <div class="clearer"></div>
  242. </div>
  243. <div class="related">
  244. <h3>Navigation</h3>
  245. <ul>
  246. <li class="right" style="margin-right: 10px">
  247. <a href="../genindex.html" title="General Index"
  248. >index</a></li>
  249. <li class="right" >
  250. <a href="../modindex.html" title="Global Module Index"
  251. >modules</a> |</li>
  252. <li class="right" >
  253. <a href="celery.datastructures.html" title="Datastructures - celery.datastructures"
  254. >next</a> |</li>
  255. <li class="right" >
  256. <a href="celery.backends.tyrant.html" title="Backend: Tokyo Tyrant - celery.backends.tyrant"
  257. >previous</a> |</li>
  258. <li><a href="../index.html">Celery v0.7.0 (unstable) documentation</a> &raquo;</li>
  259. <li><a href="index.html" >Module API Reference</a> &raquo;</li>
  260. </ul>
  261. </div>
  262. <div class="footer">
  263. &copy; Copyright 2009, Ask Solem.
  264. Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 0.6.2.
  265. </div>
  266. </body>
  267. </html>