title: Callback for celery apply_async
body: <p>I use <code>celery</code> in my application to run periodic tasks. Let's see simple example below </p>
  
  <pre><code>from myqueue import Queue
  @perodic_task(run_every=timedelta(minutes=1))
  def process_queue():
      queue = Queue()
      uid, questions = queue.pop()
      if uid is None:
          return
  
      job = group(do_stuff(q) for q in questions)
      job.apply_async()
  
  def do_stuff(question):
      try:
          ...
      except:
          ...
          raise
  </code></pre>
  
  <p>As you can see in the example above, i use <code>celery</code> to run async task, but (since it's a queue) i need to do <code>queue.fail(uid)</code> in case of exception in <code>do_stuff</code> or <code>queue.ack(uid)</code> otherwise. In this situation it would be very clear and usefull to have some callback from my task in both cases - <code>on_failure</code> and <code>on_success</code>.</p>
  
  <p>I saw some <a href="http://docs.celeryproject.org/en/latest/reference/celery.app.task.html?highlight=success#celery.app.task.Task.on_success" rel="noreferrer">documentation</a>, but never seen practices of using callbacks with <code>apply_async</code>. Is it possible to do that?</p>