Skip to content

Commit

Permalink
Merge branch '3.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
ask committed Mar 23, 2013
2 parents 913f666 + 2e3c725 commit c507bf2
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions docs/faq.rst
Original file line number Diff line number Diff line change
Expand Up @@ -423,19 +423,19 @@ Results
How do I get the result of a task if I have the ID that points there?
----------------------------------------------------------------------

**Answer**: Use `Task.AsyncResult`::
**Answer**: Use `task.AsyncResult`::

>>> result = MyTask.AsyncResult(task_id)
>>> result = my_task.AsyncResult(task_id)
>>> result.get()

This will give you a :class:`~celery.result.BaseAsyncResult` instance
This will give you a :class:`~celery.result.AsyncResult` instance
using the tasks current result backend.

If you need to specify a custom result backend you should use
:class:`celery.result.BaseAsyncResult` directly::
If you need to specify a custom result backend, or you want to use
the current application's default backend you can use
:class:`@Celery.AsyncResult`:

>>> from celery.result import BaseAsyncResult
>>> result = BaseAsyncResult(task_id, backend=...)
>>> result = app.AsyncResult(task_id)
>>> result.get()

.. _faq-security:
Expand Down

0 comments on commit c507bf2

Please sign in to comment.