changelog.html 37 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674
  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>Change history &mdash; Celery v0.3.20 (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.3.20 (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.3.20 (unstable) documentation" href="index.html" />
  21. <link rel="next" title="Interesting Links" href="links.html" />
  22. <link rel="prev" title="Celery Worker Daemon - celery.bin.celeryd" href="reference/celery.bin.celeryd.html" />
  23. </head>
  24. <body>
  25. <div class="related">
  26. <h3>Navigation</h3>
  27. <ul>
  28. <li class="right" style="margin-right: 10px">
  29. <a href="genindex.html" title="General Index"
  30. accesskey="I">index</a></li>
  31. <li class="right" >
  32. <a href="modindex.html" title="Global Module Index"
  33. accesskey="M">modules</a> |</li>
  34. <li class="right" >
  35. <a href="links.html" title="Interesting Links"
  36. accesskey="N">next</a> |</li>
  37. <li class="right" >
  38. <a href="reference/celery.bin.celeryd.html" title="Celery Worker Daemon - celery.bin.celeryd"
  39. accesskey="P">previous</a> |</li>
  40. <li><a href="index.html">Celery v0.3.20 (unstable) documentation</a> &raquo;</li>
  41. </ul>
  42. </div>
  43. <div class="document">
  44. <div class="documentwrapper">
  45. <div class="bodywrapper">
  46. <div class="body">
  47. <div class="section" id="change-history">
  48. <h1>Change history<a class="headerlink" href="#change-history" title="Permalink to this headline">¶</a></h1>
  49. <div class="section" id="p-m-cet">
  50. <h2>0.3.20 [2009-06-25 08:42 P.M CET]<a class="headerlink" href="#p-m-cet" title="Permalink to this headline">¶</a></h2>
  51. <ul>
  52. <li><dl class="first docutils">
  53. <dt>New arguments to <tt class="docutils literal"><span class="pre">apply_async</span></tt> (the advanced version of</dt>
  54. <dd><p class="first"><tt class="docutils literal"><span class="pre">delay_task</span></tt>), <tt class="docutils literal"><span class="pre">countdown</span></tt> and <tt class="docutils literal"><span class="pre">eta</span></tt>;</p>
  55. <blockquote class="last">
  56. <div class="highlight-python"><div class="highlight"><pre><span class="gp">&gt;&gt;&gt; </span><span class="c"># Run 10 seconds into the future.</span>
  57. <span class="gp">&gt;&gt;&gt; </span><span class="n">res</span> <span class="o">=</span> <span class="n">apply_async</span><span class="p">(</span><span class="n">MyTask</span><span class="p">,</span> <span class="n">countdown</span><span class="o">=</span><span class="mf">10</span><span class="p">);</span>
  58. </pre></div>
  59. </div>
  60. <div class="highlight-python"><div class="highlight"><pre><span class="gp">&gt;&gt;&gt; </span><span class="c"># Run 1 day from now</span>
  61. <span class="gp">&gt;&gt;&gt; </span><span class="n">res</span> <span class="o">=</span> <span class="n">apply_async</span><span class="p">(</span><span class="n">MyTask</span><span class="p">,</span> <span class="n">eta</span><span class="o">=</span><span class="n">datetime</span><span class="o">.</span><span class="n">now</span><span class="p">()</span> <span class="o">+</span>
  62. <span class="gp">... </span> <span class="n">timedelta</span><span class="p">(</span><span class="n">days</span><span class="o">=</span><span class="mf">1</span><span class="p">)</span>
  63. </pre></div>
  64. </div>
  65. </blockquote>
  66. </dd>
  67. </dl>
  68. </li>
  69. <li><p class="first">Now unlinks the pidfile if it&#8217;s stale.</p>
  70. </li>
  71. <li><p class="first">Lots of more tests.</p>
  72. </li>
  73. <li><p class="first">Now compatible with carrot &gt;= 0.5.0.</p>
  74. </li>
  75. <li><p class="first"><strong>IMPORTANT</strong> The <tt class="docutils literal"><span class="pre">subtask_ids</span></tt> attribute on the <tt class="docutils literal"><span class="pre">TaskSetResult</span></tt>
  76. instance has been removed. To get this information instead use:</p>
  77. <div class="highlight-python"><div class="highlight"><pre><span class="gp">&gt;&gt;&gt; </span><span class="n">subtask_ids</span> <span class="o">=</span> <span class="p">[</span><span class="n">subtask</span><span class="o">.</span><span class="n">task_id</span> <span class="k">for</span> <span class="n">subtask</span> <span class="ow">in</span> <span class="n">ts_res</span><span class="o">.</span><span class="n">subtasks</span><span class="p">]</span>
  78. </pre></div>
  79. </div>
  80. </li>
  81. <li><p class="first">Taskset.run() now respects extra message options from the task class.</p>
  82. </li>
  83. <li><dl class="first docutils">
  84. <dt>Task: Add attribute <tt class="docutils literal"><span class="pre">ignore_result</span></tt>: Don&#8217;t store the status and</dt>
  85. <dd><p class="first last">return value. This means you can&#8217;t use the
  86. <tt class="docutils literal"><span class="pre">celery.result.AsyncResult</span></tt> to check if the task is
  87. done, or get its return value. Only use if you need the performance
  88. and is able live without these features. Any exceptions raised will
  89. store the return value/status as usual.</p>
  90. </dd>
  91. </dl>
  92. </li>
  93. <li><dl class="first docutils">
  94. <dt>Task: Add attribute <tt class="docutils literal"><span class="pre">disable_error_emails</span></tt> to disable sending error</dt>
  95. <dd><p class="first last">emails for that task.</p>
  96. </dd>
  97. </dl>
  98. </li>
  99. <li><dl class="first docutils">
  100. <dt>Should now work on Windows (although running in the background won&#8217;t</dt>
  101. <dd><p class="first last">work, so using the <tt class="docutils literal"><span class="pre">--detach</span></tt> argument results in an exception
  102. being raised.)</p>
  103. </dd>
  104. </dl>
  105. </li>
  106. <li><dl class="first docutils">
  107. <dt>Added support for statistics for profiling and monitoring.</dt>
  108. <dd><p class="first last">To start sending statistics start <tt class="docutils literal"><span class="pre">celeryd</span></tt> with the
  109. <tt class="docutils literal"><span class="pre">--statistics</span></tt> option. Then after a while you can dump the results
  110. by running <tt class="docutils literal"><span class="pre">python</span> <span class="pre">manage.py</span> <span class="pre">celerystats</span></tt>. See
  111. <tt class="docutils literal"><span class="pre">celery.monitoring</span></tt> for more information.</p>
  112. </dd>
  113. </dl>
  114. </li>
  115. <li><dl class="first docutils">
  116. <dt>The celery daemon can now be supervised (i.e it is automatically</dt>
  117. <dd><p class="first last">restarted if it crashes). To use this start celeryd with the
  118. <tt class="docutils literal"><span class="pre">--supervised</span></tt> option (or alternatively <tt class="docutils literal"><span class="pre">-S</span></tt>).</p>
  119. </dd>
  120. </dl>
  121. </li>
  122. <li><p class="first">views.apply: View applying a task. Example:</p>
  123. <div class="highlight-python"><pre> http://e.com/celery/apply/task_name/arg1/arg2//?kwarg1=a&amp;kwarg2=b
  124. **NOTE** Use with caution, preferably not make this publicly
  125. accessible without ensuring your code is safe!</pre>
  126. </div>
  127. </li>
  128. <li><p class="first">Refactored celery.task. It&#8217;s now split into three modules:</p>
  129. <ul>
  130. <li><p class="first">celery.task</p>
  131. <blockquote>
  132. <p>Contains apply_async, delay_task, discard_all, and task
  133. shortcuts, plus imports objects from celery.task.base and
  134. celery.task.builtins</p>
  135. </blockquote>
  136. </li>
  137. <li><p class="first">celery.task.base</p>
  138. <blockquote>
  139. <p>Contains task base classes: Task, PeriodicTask, TaskSet</p>
  140. </blockquote>
  141. </li>
  142. <li><p class="first">celery.task.builtins</p>
  143. <blockquote>
  144. <p>Built-in tasks: PingTask, AsynchronousMapTask,
  145. ExecuteRemoteTask, ++.</p>
  146. </blockquote>
  147. </li>
  148. </ul>
  149. </li>
  150. </ul>
  151. </div>
  152. <div class="section" id="id1">
  153. <h2>0.3.7 [2008-06-16 11:41 P.M CET]<a class="headerlink" href="#id1" title="Permalink to this headline">¶</a></h2>
  154. <ul>
  155. <li><dl class="first docutils">
  156. <dt><strong>IMPORTANT</strong> Now uses AMQP&#8217;s <tt class="docutils literal"><span class="pre">basic.consume</span></tt> instead of</dt>
  157. <dd><p class="first last"><tt class="docutils literal"><span class="pre">basic.get</span></tt>. This means we&#8217;re no longer polling the broker for
  158. new messages.</p>
  159. </dd>
  160. </dl>
  161. </li>
  162. <li><dl class="first docutils">
  163. <dt><strong>IMPORTANT</strong> Default concurrency limit is now set to the number of CPUs</dt>
  164. <dd><p class="first last">available on the system.</p>
  165. </dd>
  166. </dl>
  167. </li>
  168. <li><dl class="first docutils">
  169. <dt><strong>IMPORTANT</strong> <tt class="docutils literal"><span class="pre">tasks.register</span></tt>: Renamed <tt class="docutils literal"><span class="pre">task_name</span></tt> argument to</dt>
  170. <dd><p class="first"><tt class="docutils literal"><span class="pre">name</span></tt>, so</p>
  171. <div class="highlight-python"><div class="highlight"><pre><span class="gp">&gt;&gt;&gt; </span><span class="n">tasks</span><span class="o">.</span><span class="n">register</span><span class="p">(</span><span class="n">func</span><span class="p">,</span> <span class="n">task_name</span><span class="o">=</span><span class="s">&quot;mytask&quot;</span><span class="p">)</span>
  172. </pre></div>
  173. </div>
  174. <p>has to be replaced with:</p>
  175. <div class="last highlight-python"><div class="highlight"><pre><span class="gp">&gt;&gt;&gt; </span><span class="n">tasks</span><span class="o">.</span><span class="n">register</span><span class="p">(</span><span class="n">func</span><span class="p">,</span> <span class="n">name</span><span class="o">=</span><span class="s">&quot;mytask&quot;</span><span class="p">)</span>
  176. </pre></div>
  177. </div>
  178. </dd>
  179. </dl>
  180. </li>
  181. <li><p class="first">The daemon now correctly runs if the pidlock is stale.</p>
  182. </li>
  183. <li><p class="first">Now compatible with carrot 0.4.5</p>
  184. </li>
  185. <li><p class="first">Default AMQP connnection timeout is now 4 seconds.</p>
  186. </li>
  187. <li><p class="first"><tt class="docutils literal"><span class="pre">AsyncResult.read()</span></tt> was always returning <tt class="xref docutils literal"><span class="pre">True</span></tt>.</p>
  188. </li>
  189. <li><dl class="first docutils">
  190. <dt>Only use README as long_description if the file exists so easy_install</dt>
  191. <dd><p class="first last">doesn&#8217;t break.</p>
  192. </dd>
  193. </dl>
  194. </li>
  195. <li><p class="first"><tt class="docutils literal"><span class="pre">celery.view</span></tt>: JSON responses now properly set its mime-type.</p>
  196. </li>
  197. <li><dl class="first docutils">
  198. <dt><tt class="docutils literal"><span class="pre">apply_async</span></tt> now has a <tt class="docutils literal"><span class="pre">connection</span></tt> keyword argument so you</dt>
  199. <dd><p class="first last">can re-use the same AMQP connection if you want to execute
  200. more than one task.</p>
  201. </dd>
  202. </dl>
  203. </li>
  204. <li><p class="first">Handle failures in task_status view such that it won&#8217;t throw 500s.</p>
  205. </li>
  206. <li><p class="first">Fixed typo <tt class="docutils literal"><span class="pre">AMQP_SERVER</span></tt> in documentation to <tt class="docutils literal"><span class="pre">AMQP_HOST</span></tt>.</p>
  207. </li>
  208. <li><p class="first">Worker exception e-mails sent to admins now works properly.</p>
  209. </li>
  210. <li><dl class="first docutils">
  211. <dt>No longer depends on <tt class="docutils literal"><span class="pre">django</span></tt>, so installing <tt class="docutils literal"><span class="pre">celery</span></tt> won&#8217;t affect</dt>
  212. <dd><p class="first last">the preferred Django version installed.</p>
  213. </dd>
  214. </dl>
  215. </li>
  216. <li><dl class="first docutils">
  217. <dt>Now works with PostgreSQL (psycopg2) again by registering the</dt>
  218. <dd><p class="first last"><tt class="docutils literal"><span class="pre">PickledObject</span></tt> field.</p>
  219. </dd>
  220. </dl>
  221. </li>
  222. <li><dl class="first docutils">
  223. <dt><tt class="docutils literal"><span class="pre">celeryd</span></tt>: Added <tt class="docutils literal"><span class="pre">--detach</span></tt> option as an alias to <tt class="docutils literal"><span class="pre">--daemon</span></tt>, and</dt>
  224. <dd><p class="first last">it&#8217;s the term used in the documentation from now on.</p>
  225. </dd>
  226. </dl>
  227. </li>
  228. <li><dl class="first docutils">
  229. <dt>Make sure the pool and periodic task worker thread is terminated</dt>
  230. <dd><p class="first last">properly at exit. (So <tt class="docutils literal"><span class="pre">Ctrl-C</span></tt> works again).</p>
  231. </dd>
  232. </dl>
  233. </li>
  234. <li><p class="first">Now depends on <tt class="docutils literal"><span class="pre">python-daemon</span></tt>.</p>
  235. </li>
  236. <li><p class="first">Removed dependency to <tt class="docutils literal"><span class="pre">simplejson</span></tt></p>
  237. </li>
  238. <li><dl class="first docutils">
  239. <dt>Cache Backend: Re-establishes connection for every task process</dt>
  240. <dd><p class="first last">if the Django cache backend is memcached/libmemcached.</p>
  241. </dd>
  242. </dl>
  243. </li>
  244. <li><dl class="first docutils">
  245. <dt>Tyrant Backend: Now re-establishes the connection for every task</dt>
  246. <dd><p class="first last">executed.</p>
  247. </dd>
  248. </dl>
  249. </li>
  250. </ul>
  251. </div>
  252. <div class="section" id="id2">
  253. <h2>0.3.3 [2009-06-08 01:07 P.M CET]<a class="headerlink" href="#id2" title="Permalink to this headline">¶</a></h2>
  254. <ul>
  255. <li><dl class="first docutils">
  256. <dt>The <tt class="docutils literal"><span class="pre">PeriodicWorkController</span></tt> now sleeps for 1 second between checking</dt>
  257. <dd><p class="first last">for periodic tasks to execute.</p>
  258. </dd>
  259. </dl>
  260. </li>
  261. </ul>
  262. </div>
  263. <div class="section" id="id3">
  264. <h2>0.3.2 [2009-06-08 01:07 P.M CET]<a class="headerlink" href="#id3" title="Permalink to this headline">¶</a></h2>
  265. <ul>
  266. <li><dl class="first docutils">
  267. <dt>celeryd: Added option <tt class="docutils literal"><span class="pre">--discard</span></tt>: Discard (delete!) all waiting</dt>
  268. <dd><p class="first last">messages in the queue.</p>
  269. </dd>
  270. </dl>
  271. </li>
  272. <li><p class="first">celeryd: The <tt class="docutils literal"><span class="pre">--wakeup-after</span></tt> option was not handled as a float.</p>
  273. </li>
  274. </ul>
  275. </div>
  276. <div class="section" id="id4">
  277. <h2>0.3.1 [2009-06-08 01:07 P.M CET]<a class="headerlink" href="#id4" title="Permalink to this headline">¶</a></h2>
  278. <ul>
  279. <li><dl class="first docutils">
  280. <dt>The <cite>PeriodicTask`</cite> worker is now running in its own thread instead</dt>
  281. <dd><p class="first last">of blocking the <tt class="docutils literal"><span class="pre">TaskController</span></tt> loop.</p>
  282. </dd>
  283. </dl>
  284. </li>
  285. <li><p class="first">Default <tt class="docutils literal"><span class="pre">QUEUE_WAKEUP_AFTER</span></tt> has been lowered to <tt class="docutils literal"><span class="pre">0.1</span></tt> (was <tt class="docutils literal"><span class="pre">0.3</span></tt>)</p>
  286. </li>
  287. </ul>
  288. </div>
  289. <div class="section" id="id5">
  290. <h2>0.3.0 [2009-06-08 12:41 P.M CET]<a class="headerlink" href="#id5" title="Permalink to this headline">¶</a></h2>
  291. <p><strong>NOTE</strong> This is a development version, for the stable release, please
  292. see versions 0.2.x.</p>
  293. <p><strong>VERY IMPORTANT:</strong> Pickle is now the encoder used for serializing task
  294. arguments, so be sure to flush your task queue before you upgrade.</p>
  295. <ul>
  296. <li><dl class="first docutils">
  297. <dt><strong>IMPORTANT</strong> TaskSet.run() now returns a celery.result.TaskSetResult</dt>
  298. <dd><p class="first last">instance, which lets you inspect the status and return values of a
  299. taskset as it was a single entity.</p>
  300. </dd>
  301. </dl>
  302. </li>
  303. <li><p class="first"><strong>IMPORTANT</strong> Celery now depends on carrot &gt;= 0.4.1.</p>
  304. </li>
  305. <li><dl class="first docutils">
  306. <dt>The celery daemon now sends task errors to the registered admin e-mails.</dt>
  307. <dd><p class="first last">To turn off this feature, set <tt class="docutils literal"><span class="pre">SEND_CELERY_TASK_ERROR_EMAILS</span></tt> to
  308. <tt class="xref docutils literal"><span class="pre">False</span></tt> in your <tt class="docutils literal"><span class="pre">settings.py</span></tt>. Thanks to Grégoire Cachet.</p>
  309. </dd>
  310. </dl>
  311. </li>
  312. <li><p class="first">You can now run the celery daemon by using <tt class="docutils literal"><span class="pre">manage.py</span></tt>:</p>
  313. <div class="highlight-python"><pre> $ python manage.py celeryd
  314. Thanks to Grégoire Cachet.</pre>
  315. </div>
  316. </li>
  317. <li><dl class="first docutils">
  318. <dt>Added support for message priorities, topic exchanges, custom routing</dt>
  319. <dd><p class="first">keys for tasks. This means we have introduced
  320. <tt class="docutils literal"><span class="pre">celery.task.apply_async</span></tt>, a new way of executing tasks.</p>
  321. <p>You can use <tt class="docutils literal"><span class="pre">celery.task.delay</span></tt> and <tt class="docutils literal"><span class="pre">celery.Task.delay</span></tt> like usual, but
  322. if you want greater control over the message sent, you want
  323. <tt class="docutils literal"><span class="pre">celery.task.apply_async</span></tt> and <tt class="docutils literal"><span class="pre">celery.Task.apply_async</span></tt>.</p>
  324. <p>This also means the AMQP configuration has changed. Some settings has
  325. been renamed, while others are new:</p>
  326. <div class="highlight-python"><div class="highlight"><pre><span class="n">CELERY_AMQP_EXCHANGE</span>
  327. <span class="n">CELERY_AMQP_PUBLISHER_ROUTING_KEY</span>
  328. <span class="n">CELERY_AMQP_CONSUMER_ROUTING_KEY</span>
  329. <span class="n">CELERY_AMQP_CONSUMER_QUEUE</span>
  330. <span class="n">CELERY_AMQP_EXCHANGE_TYPE</span>
  331. </pre></div>
  332. </div>
  333. <p class="last">See the entry <a class="reference external" href="http://bit.ly/celery_AMQP_routing">Can I send some tasks to only some servers?</a> in the
  334. <a class="reference external" href="http://ask.github.com/celery/faq.html">FAQ</a> for more information.</p>
  335. </dd>
  336. </dl>
  337. </li>
  338. </ul>
  339. <ul>
  340. <li><dl class="first docutils">
  341. <dt>Task errors are now logged using loglevel <tt class="docutils literal"><span class="pre">ERROR</span></tt> instead of <tt class="docutils literal"><span class="pre">INFO</span></tt>,</dt>
  342. <dd><p class="first last">and backtraces are dumped. Thanks to Grégoire Cachet.</p>
  343. </dd>
  344. </dl>
  345. </li>
  346. <li><dl class="first docutils">
  347. <dt>Make every new worker process re-establish it&#8217;s Django DB connection,</dt>
  348. <dd><p class="first last">this solving the &#8220;MySQL connection died?&#8221; exceptions.
  349. Thanks to Vitaly Babiy and Jirka Vejrazka.</p>
  350. </dd>
  351. </dl>
  352. </li>
  353. <li><dl class="first docutils">
  354. <dt><strong>IMOPORTANT</strong> Now using pickle to encode task arguments. This means you</dt>
  355. <dd><p class="first last">now can pass complex python objects to tasks as arguments.</p>
  356. </dd>
  357. </dl>
  358. </li>
  359. <li><p class="first">Removed dependency on <tt class="docutils literal"><span class="pre">yadayada</span></tt>.</p>
  360. </li>
  361. <li><p class="first">Added a FAQ, see <tt class="docutils literal"><span class="pre">docs/faq.rst</span></tt>.</p>
  362. </li>
  363. <li><dl class="first docutils">
  364. <dt>Now converts any unicode keys in task <tt class="docutils literal"><span class="pre">kwargs</span></tt> to regular strings.</dt>
  365. <dd><p class="first last">Thanks Vitaly Babiy.</p>
  366. </dd>
  367. </dl>
  368. </li>
  369. <li><p class="first">Renamed the <tt class="docutils literal"><span class="pre">TaskDaemon</span></tt> to <tt class="docutils literal"><span class="pre">WorkController</span></tt>.</p>
  370. </li>
  371. <li><dl class="first docutils">
  372. <dt><tt class="docutils literal"><span class="pre">celery.datastructures.TaskProcessQueue</span></tt> is now renamed to</dt>
  373. <dd><p class="first last"><tt class="docutils literal"><span class="pre">celery.pool.TaskPool</span></tt>.</p>
  374. </dd>
  375. </dl>
  376. </li>
  377. <li><dl class="first docutils">
  378. <dt>The pool algorithm has been refactored for greater performance and</dt>
  379. <dd><p class="first last">stability.</p>
  380. </dd>
  381. </dl>
  382. </li>
  383. </ul>
  384. </div>
  385. <div class="section" id="id6">
  386. <h2>0.2.0 [2009-05-20 05:14 P.M CET]<a class="headerlink" href="#id6" title="Permalink to this headline">¶</a></h2>
  387. <ul class="simple">
  388. <li>Final release of 0.2.0</li>
  389. <li>Compatible with carrot version 0.4.0.</li>
  390. <li>Fixes some syntax errors related to fetching results
  391. from the database backend.</li>
  392. </ul>
  393. </div>
  394. <div class="section" id="pre3-2009-05-20-05-14-p-m-cet">
  395. <h2>0.2.0-pre3 [2009-05-20 05:14 P.M CET]<a class="headerlink" href="#pre3-2009-05-20-05-14-p-m-cet" title="Permalink to this headline">¶</a></h2>
  396. <ul>
  397. <li><dl class="first docutils">
  398. <dt><em>Internal release</em>. Improved handling of unpickled exceptions,</dt>
  399. <dd><p class="first last">get_result() now tries to recreate something looking like the
  400. original exception.</p>
  401. </dd>
  402. </dl>
  403. </li>
  404. </ul>
  405. </div>
  406. <div class="section" id="pre2-2009-05-20-01-56-p-m-cet">
  407. <h2>0.2.0-pre2 [2009-05-20 01:56 P.M CET]<a class="headerlink" href="#pre2-2009-05-20-01-56-p-m-cet" title="Permalink to this headline">¶</a></h2>
  408. <ul class="simple">
  409. <li>Now handles unpickleable exceptions (like the dynimically generated
  410. subclasses of <tt class="docutils literal"><span class="pre">django.core.exception.MultipleObjectsReturned</span></tt>).</li>
  411. </ul>
  412. </div>
  413. <div class="section" id="pre1-2009-05-20-12-33-p-m-cet">
  414. <h2>0.2.0-pre1 [2009-05-20 12:33 P.M CET]<a class="headerlink" href="#pre1-2009-05-20-12-33-p-m-cet" title="Permalink to this headline">¶</a></h2>
  415. <ul class="simple">
  416. <li>It&#8217;s getting quite stable, with a lot of new features, so bump
  417. version to 0.2. This is a pre-release.</li>
  418. <li><tt class="docutils literal"><span class="pre">celery.task.mark_as_read()</span></tt> and <tt class="docutils literal"><span class="pre">celery.task.mark_as_failure()</span></tt> has
  419. been removed. Use <tt class="docutils literal"><span class="pre">celery.backends.default_backend.mark_as_read()</span></tt>,
  420. and <tt class="docutils literal"><span class="pre">celery.backends.default_backend.mark_as_failure()</span></tt> instead.</li>
  421. </ul>
  422. </div>
  423. <div class="section" id="id7">
  424. <h2>0.1.15 [2009-05-19 04:13 P.M CET]<a class="headerlink" href="#id7" title="Permalink to this headline">¶</a></h2>
  425. <ul class="simple">
  426. <li>The celery daemon was leaking AMQP connections, this should be fixed,
  427. if you have any problems with too many files open (like <tt class="docutils literal"><span class="pre">emfile</span></tt>
  428. errors in <tt class="docutils literal"><span class="pre">rabbit.log</span></tt>, please contact us!</li>
  429. </ul>
  430. </div>
  431. <div class="section" id="id8">
  432. <h2>0.1.14 [2009-05-19 01:08 P.M CET]<a class="headerlink" href="#id8" title="Permalink to this headline">¶</a></h2>
  433. <ul class="simple">
  434. <li>Fixed a syntax error in the <tt class="docutils literal"><span class="pre">TaskSet</span></tt> class. (No such variable
  435. <tt class="docutils literal"><span class="pre">TimeOutError</span></tt>).</li>
  436. </ul>
  437. </div>
  438. <div class="section" id="id9">
  439. <h2>0.1.13 [2009-05-19 12:36 P.M CET]<a class="headerlink" href="#id9" title="Permalink to this headline">¶</a></h2>
  440. <ul>
  441. <li><p class="first">Forgot to add <tt class="docutils literal"><span class="pre">yadayada</span></tt> to install requirements.</p>
  442. </li>
  443. <li><p class="first">Now deletes all expired task results, not just those marked as done.</p>
  444. </li>
  445. <li><p class="first">Able to load the Tokyo Tyrant backend class without django
  446. configuration, can specify tyrant settings directly in the class
  447. constructor.</p>
  448. </li>
  449. <li><p class="first">Improved API documentation</p>
  450. </li>
  451. <li><p class="first">Now using the Sphinx documentation system, you can build
  452. the html documentation by doing</p>
  453. <div class="highlight-python"><pre>$ cd docs
  454. $ make html</pre>
  455. </div>
  456. <p>and the result will be in <tt class="docutils literal"><span class="pre">docs/.build/html</span></tt>.</p>
  457. </li>
  458. </ul>
  459. </div>
  460. <div class="section" id="id10">
  461. <h2>0.1.12 [2009-05-18 04:38 P.M CET]<a class="headerlink" href="#id10" title="Permalink to this headline">¶</a></h2>
  462. <ul>
  463. <li><p class="first"><tt class="docutils literal"><span class="pre">delay_task()</span></tt> etc. now returns <tt class="docutils literal"><span class="pre">celery.task.AsyncResult</span></tt> object,
  464. which lets you check the result and any failure that might have
  465. happened. It kind of works like the <tt class="docutils literal"><span class="pre">multiprocessing.AsyncResult</span></tt>
  466. class returned by <tt class="docutils literal"><span class="pre">multiprocessing.Pool.map_async</span></tt>.</p>
  467. </li>
  468. <li><p class="first">Added dmap() and dmap_async(). This works like the
  469. <tt class="docutils literal"><span class="pre">multiprocessing.Pool</span></tt> versions except they are tasks
  470. distributed to the celery server. Example:</p>
  471. <blockquote>
  472. <div class="highlight-python"><div class="highlight"><pre><span class="gp">&gt;&gt;&gt; </span><span class="kn">from</span> <span class="nn">celery.task</span> <span class="kn">import</span> <span class="n">dmap</span>
  473. <span class="gp">&gt;&gt;&gt; </span><span class="kn">import</span> <span class="nn">operator</span>
  474. <span class="gp">&gt;&gt;&gt; </span><span class="n">dmap</span><span class="p">(</span><span class="n">operator</span><span class="o">.</span><span class="n">add</span><span class="p">,</span> <span class="p">[[</span><span class="mf">2</span><span class="p">,</span> <span class="mf">2</span><span class="p">],</span> <span class="p">[</span><span class="mf">4</span><span class="p">,</span> <span class="mf">4</span><span class="p">],</span> <span class="p">[</span><span class="mf">8</span><span class="p">,</span> <span class="mf">8</span><span class="p">]])</span>
  475. <span class="gp">&gt;&gt;&gt; </span><span class="p">[</span><span class="mf">4</span><span class="p">,</span> <span class="mf">8</span><span class="p">,</span> <span class="mf">16</span><span class="p">]</span>
  476. </pre></div>
  477. </div>
  478. <div class="highlight-python"><div class="highlight"><pre><span class="gp">&gt;&gt;&gt; </span><span class="kn">from</span> <span class="nn">celery.task</span> <span class="kn">import</span> <span class="n">dmap_async</span>
  479. <span class="gp">&gt;&gt;&gt; </span><span class="kn">import</span> <span class="nn">operator</span>
  480. <span class="gp">&gt;&gt;&gt; </span><span class="n">result</span> <span class="o">=</span> <span class="n">dmap_async</span><span class="p">(</span><span class="n">operator</span><span class="o">.</span><span class="n">add</span><span class="p">,</span> <span class="p">[[</span><span class="mf">2</span><span class="p">,</span> <span class="mf">2</span><span class="p">],</span> <span class="p">[</span><span class="mf">4</span><span class="p">,</span> <span class="mf">4</span><span class="p">],</span> <span class="p">[</span><span class="mf">8</span><span class="p">,</span> <span class="mf">8</span><span class="p">]])</span>
  481. <span class="gp">&gt;&gt;&gt; </span><span class="n">result</span><span class="o">.</span><span class="n">ready</span><span class="p">()</span>
  482. <span class="go">False</span>
  483. <span class="gp">&gt;&gt;&gt; </span><span class="n">time</span><span class="o">.</span><span class="n">sleep</span><span class="p">(</span><span class="mf">1</span><span class="p">)</span>
  484. <span class="gp">&gt;&gt;&gt; </span><span class="n">result</span><span class="o">.</span><span class="n">ready</span><span class="p">()</span>
  485. <span class="go">True</span>
  486. <span class="gp">&gt;&gt;&gt; </span><span class="n">result</span><span class="o">.</span><span class="n">result</span>
  487. <span class="go">[4, 8, 16]</span>
  488. </pre></div>
  489. </div>
  490. </blockquote>
  491. </li>
  492. <li><p class="first">Refactored the task metadata cache and database backends, and added a new backend for Tokyo Tyrant. You can set the backend in your django settings file. e.g</p>
  493. <blockquote>
  494. <p>CELERY_BACKEND = &#8220;database&#8221;; # Uses the database</p>
  495. <p>CELERY_BACKEND = &#8220;cache&#8221;; # Uses the django cache framework</p>
  496. <p>CELERY_BACKEND = &#8220;tyrant&#8221;; # Uses Tokyo Tyrant
  497. TT_HOST = &#8220;localhost&#8221;; # Hostname for the Tokyo Tyrant server.
  498. TT_PORT = 6657; # Port of the Tokyo Tyrant server.</p>
  499. </blockquote>
  500. </li>
  501. </ul>
  502. </div>
  503. <div class="section" id="id11">
  504. <h2>0.1.11 [2009-05-12 02:08 P.M CET]<a class="headerlink" href="#id11" title="Permalink to this headline">¶</a></h2>
  505. <ul class="simple">
  506. <li>The logging system was leaking file descriptors, resulting in
  507. servers stopping with the EMFILES (too many open files) error. (fixed)</li>
  508. </ul>
  509. </div>
  510. <div class="section" id="id12">
  511. <h2>0.1.10 [2009-05-11 12:46 P.M CET]<a class="headerlink" href="#id12" title="Permalink to this headline">¶</a></h2>
  512. <ul class="simple">
  513. <li>Tasks now supports both positional arguments and keyword arguments.</li>
  514. <li>Requires carrot 0.3.8.</li>
  515. <li>The daemon now tries to reconnect if the connection is lost.</li>
  516. </ul>
  517. </div>
  518. <div class="section" id="id13">
  519. <h2>0.1.8 [2009-05-07 12:27 P.M CET]<a class="headerlink" href="#id13" title="Permalink to this headline">¶</a></h2>
  520. <ul class="simple">
  521. <li>Better test coverage</li>
  522. <li>More documentation</li>
  523. <li>celeryd doesn&#8217;t emit <tt class="docutils literal"><span class="pre">Queue</span> <span class="pre">is</span> <span class="pre">empty</span></tt> message if
  524. <tt class="docutils literal"><span class="pre">settings.CELERYD_EMPTY_MSG_EMIT_EVERY</span></tt> is 0.</li>
  525. </ul>
  526. </div>
  527. <div class="section" id="id14">
  528. <h2>0.1.7 [2009-04-30 1:50 P.M CET]<a class="headerlink" href="#id14" title="Permalink to this headline">¶</a></h2>
  529. <ul class="simple">
  530. <li>Added some unittests</li>
  531. <li>Can now use the database for task metadata (like if the task has
  532. been executed or not). Set <tt class="docutils literal"><span class="pre">settings.CELERY_TASK_META</span></tt></li>
  533. <li>Can now run <tt class="docutils literal"><span class="pre">python</span> <span class="pre">setup.py</span> <span class="pre">test</span></tt> to run the unittests from
  534. within the <tt class="docutils literal"><span class="pre">testproj</span></tt> project.</li>
  535. <li>Can set the AMQP exchange/routing key/queue using
  536. <tt class="docutils literal"><span class="pre">settings.CELERY_AMQP_EXCHANGE</span></tt>, <tt class="docutils literal"><span class="pre">settings.CELERY_AMQP_ROUTING_KEY</span></tt>,
  537. and <tt class="docutils literal"><span class="pre">settings.CELERY_AMQP_CONSUMER_QUEUE</span></tt>.</li>
  538. </ul>
  539. </div>
  540. <div class="section" id="id15">
  541. <h2>0.1.6 [2009-04-28 2:13 P.M CET]<a class="headerlink" href="#id15" title="Permalink to this headline">¶</a></h2>
  542. <blockquote>
  543. <ul class="simple">
  544. <li>Introducing <tt class="docutils literal"><span class="pre">TaskSet</span></tt>. A set of subtasks is executed and you can
  545. find out how many, or if all them, are done (excellent for progress bars and such)</li>
  546. <li>Now catches all exceptions when running <tt class="docutils literal"><span class="pre">Task.__call__</span></tt>, so the
  547. daemon doesn&#8217;t die. This does&#8217;t happen for pure functions yet, only
  548. <tt class="docutils literal"><span class="pre">Task</span></tt> classes.</li>
  549. <li><tt class="docutils literal"><span class="pre">autodiscover()</span></tt> now works with zipped eggs.</li>
  550. <li>celeryd: Now adds curernt working directory to <tt class="docutils literal"><span class="pre">sys.path</span></tt> for
  551. convenience.</li>
  552. <li>The <tt class="docutils literal"><span class="pre">run_every</span></tt> attribute of <tt class="docutils literal"><span class="pre">PeriodicTask</span></tt> classes can now be a
  553. <tt class="docutils literal"><span class="pre">datetime.timedelta()</span></tt> object.</li>
  554. <li>celeryd: You can now set the <tt class="docutils literal"><span class="pre">DJANGO_PROJECT_DIR</span></tt> variable
  555. for <tt class="docutils literal"><span class="pre">celeryd</span></tt> and it will add that to <tt class="docutils literal"><span class="pre">sys.path</span></tt> for easy launching.</li>
  556. <li>Can now check if a task has been executed or not via HTTP.</li>
  557. </ul>
  558. <p>You can do this by including the celery <tt class="docutils literal"><span class="pre">urls.py</span></tt> into your project,</p>
  559. <div class="highlight-python"><div class="highlight"><pre><span class="gp">&gt;&gt;&gt; </span><span class="n">url</span><span class="p">(</span><span class="s">r&#39;^celery/$&#39;</span><span class="p">,</span> <span class="n">include</span><span class="p">(</span><span class="s">&quot;celery.urls&quot;</span><span class="p">))</span>
  560. </pre></div>
  561. </div>
  562. <p>then visiting the following url,:</p>
  563. <div class="highlight-python"><pre>http://mysite/celery/$task_id/done/</pre>
  564. </div>
  565. <p>this will return a JSON dictionary like e.g:</p>
  566. <div class="highlight-python"><pre>&gt;&gt;&gt; {"task": {"id": $task_id, "executed": true}}</pre>
  567. </div>
  568. <ul class="simple">
  569. <li><tt class="docutils literal"><span class="pre">delay_task</span></tt> now returns string id, not <tt class="docutils literal"><span class="pre">uuid.UUID</span></tt> instance.</li>
  570. <li>Now has <tt class="docutils literal"><span class="pre">PeriodicTasks</span></tt>, to have <tt class="docutils literal"><span class="pre">cron</span></tt> like functionality.</li>
  571. <li>Project changed name from <tt class="docutils literal"><span class="pre">crunchy</span></tt> to <tt class="docutils literal"><span class="pre">celery</span></tt>. The details of
  572. the name change request is in <tt class="docutils literal"><span class="pre">docs/name_change_request.txt</span></tt>.</li>
  573. </ul>
  574. </blockquote>
  575. </div>
  576. <div class="section" id="a-m-cet">
  577. <h2>0.1.0 [2009-04-24 11:28 A.M CET]<a class="headerlink" href="#a-m-cet" title="Permalink to this headline">¶</a></h2>
  578. <ul class="simple">
  579. <li>Initial release</li>
  580. </ul>
  581. </div>
  582. </div>
  583. </div>
  584. </div>
  585. </div>
  586. <div class="sphinxsidebar">
  587. <div class="sphinxsidebarwrapper">
  588. <h3><a href="index.html">Table Of Contents</a></h3>
  589. <ul>
  590. <li><a class="reference external" href="">Change history</a><ul>
  591. <li><a class="reference external" href="#p-m-cet">0.3.20 [2009-06-25 08:42 P.M CET]</a></li>
  592. <li><a class="reference external" href="#id1">0.3.7 [2008-06-16 11:41 P.M CET]</a></li>
  593. <li><a class="reference external" href="#id2">0.3.3 [2009-06-08 01:07 P.M CET]</a></li>
  594. <li><a class="reference external" href="#id3">0.3.2 [2009-06-08 01:07 P.M CET]</a></li>
  595. <li><a class="reference external" href="#id4">0.3.1 [2009-06-08 01:07 P.M CET]</a></li>
  596. <li><a class="reference external" href="#id5">0.3.0 [2009-06-08 12:41 P.M CET]</a></li>
  597. <li><a class="reference external" href="#id6">0.2.0 [2009-05-20 05:14 P.M CET]</a></li>
  598. <li><a class="reference external" href="#pre3-2009-05-20-05-14-p-m-cet">0.2.0-pre3 [2009-05-20 05:14 P.M CET]</a></li>
  599. <li><a class="reference external" href="#pre2-2009-05-20-01-56-p-m-cet">0.2.0-pre2 [2009-05-20 01:56 P.M CET]</a></li>
  600. <li><a class="reference external" href="#pre1-2009-05-20-12-33-p-m-cet">0.2.0-pre1 [2009-05-20 12:33 P.M CET]</a></li>
  601. <li><a class="reference external" href="#id7">0.1.15 [2009-05-19 04:13 P.M CET]</a></li>
  602. <li><a class="reference external" href="#id8">0.1.14 [2009-05-19 01:08 P.M CET]</a></li>
  603. <li><a class="reference external" href="#id9">0.1.13 [2009-05-19 12:36 P.M CET]</a></li>
  604. <li><a class="reference external" href="#id10">0.1.12 [2009-05-18 04:38 P.M CET]</a></li>
  605. <li><a class="reference external" href="#id11">0.1.11 [2009-05-12 02:08 P.M CET]</a></li>
  606. <li><a class="reference external" href="#id12">0.1.10 [2009-05-11 12:46 P.M CET]</a></li>
  607. <li><a class="reference external" href="#id13">0.1.8 [2009-05-07 12:27 P.M CET]</a></li>
  608. <li><a class="reference external" href="#id14">0.1.7 [2009-04-30 1:50 P.M CET]</a></li>
  609. <li><a class="reference external" href="#id15">0.1.6 [2009-04-28 2:13 P.M CET]</a></li>
  610. <li><a class="reference external" href="#a-m-cet">0.1.0 [2009-04-24 11:28 A.M CET]</a></li>
  611. </ul>
  612. </li>
  613. </ul>
  614. <h4>Previous topic</h4>
  615. <p class="topless"><a href="reference/celery.bin.celeryd.html"
  616. title="previous chapter">Celery Worker Daemon - celery.bin.celeryd</a></p>
  617. <h4>Next topic</h4>
  618. <p class="topless"><a href="links.html"
  619. title="next chapter">Interesting Links</a></p>
  620. <h3>This Page</h3>
  621. <ul class="this-page-menu">
  622. <li><a href="sources/changelog.txt"
  623. rel="nofollow">Show Source</a></li>
  624. </ul>
  625. <div id="searchbox" style="display: none">
  626. <h3>Quick search</h3>
  627. <form class="search" action="search.html" method="get">
  628. <input type="text" name="q" size="18" />
  629. <input type="submit" value="Go" />
  630. <input type="hidden" name="check_keywords" value="yes" />
  631. <input type="hidden" name="area" value="default" />
  632. </form>
  633. <p class="searchtip" style="font-size: 90%">
  634. Enter search terms or a module, class or function name.
  635. </p>
  636. </div>
  637. <script type="text/javascript">$('#searchbox').show(0);</script>
  638. </div>
  639. </div>
  640. <div class="clearer"></div>
  641. </div>
  642. <div class="related">
  643. <h3>Navigation</h3>
  644. <ul>
  645. <li class="right" style="margin-right: 10px">
  646. <a href="genindex.html" title="General Index"
  647. >index</a></li>
  648. <li class="right" >
  649. <a href="modindex.html" title="Global Module Index"
  650. >modules</a> |</li>
  651. <li class="right" >
  652. <a href="links.html" title="Interesting Links"
  653. >next</a> |</li>
  654. <li class="right" >
  655. <a href="reference/celery.bin.celeryd.html" title="Celery Worker Daemon - celery.bin.celeryd"
  656. >previous</a> |</li>
  657. <li><a href="index.html">Celery v0.3.20 (unstable) documentation</a> &raquo;</li>
  658. </ul>
  659. </div>
  660. <div class="footer">
  661. &copy; Copyright 2009, Ask Solem.
  662. Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 0.6.2.
  663. </div>
  664. </body>
  665. </html>