memory result backend hanging on get() #1276

Closed
bcajes opened this Issue Apr 3, 2013 · 1 comment

2 participants

@bcajes

Using the following settings and calling my_task_results.get() hangs:

CELERY_RESULT_BACKEND = "cache"
CELERY_CACHE_BACKEND = "memory"

Using other backends seem to work as expected. No errors reported. In fact, celery monitor shows all tasks were successful.

@ask
Celery member

Not sure how this would work exactly, the worker does not have access to the memory of the parent...

If you want to use the in-memory cache backend you would have to write the result before
you can retrieve it:

>>> result = add.delay(2, 2)
>>> add.backend.mark_as_done(result.id, 4)
>>> result.get()
4
@ask ask closed this Apr 10, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment