<h1 dir="auto">Checklist</h1>


<h1 dir="auto">Checklist</h1>

<ul class="contains-task-list">
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have checked the <a href="https://github.com/celery/celery/issues?utf8=%E2%9C%93&amp;q=is%3Aissue+label%3A%22Issue+Type%3A+Feature+Request%22+">issues list</a> for similar or identical feature requests.</li>
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have checked the <a href="https://github.com/celery/celery/pulls?utf8=%E2%9C%93&amp;q=is%3Apr+label%3A%22PR+Type%3A+Feature%22+">pull requests list</a> for existing proposed implementations of this feature.</li>
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have checked the <a href="https://github.com/celery/celery/commits/master">commit log</a> to find out if the if the same feature was already implemented in the master branch.</li>
<li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have included all related issues and possible duplicate issues in this issue (If there are none, check this box anyway).</li>
</ul>
<h1 dir="auto">Brief Summary</h1>

<p dir="auto">In debugging another problem I noticed that the default connection timeout for the Redis result backend is unconfigurable, and the timeout is hardcoded at 20s (20 x 1s retries)</p>
<p dir="auto">This appears to be only actually an issue for the Redis backend (RPC is the only other backend that appears to do anything in <code class="notranslate">on_task_call</code>)</p>
<p dir="auto"><code class="notranslate">task.apply_async()</code> calls  these functions</p>
<p dir="auto"></p><div class="Box Box--condensed my-2">
  <div class="Box-header f6">
    <p class="mb-0 text-bold">
      <a href="https://github.com/celery/celery/blob/d3863d909759f1fd618f2a1af1766ce54c16d39b/celery/app/base.py#L776-L780">celery/celery/app/base.py</a>
    </p>
    <p class="mb-0 color-fg-muted">
        Lines 776 to 780
      in
      <a data-pjax="true" class="commit-tease-sha" href="/celery/celery/commit/d3863d909759f1fd618f2a1af1766ce54c16d39b">d3863d9</a>
    </p>
  </div>
  <div itemprop="text" class="Box-body p-0 blob-wrapper blob-wrapper-embedded data">
    <table class="highlight tab-size mb-0 js-file-line-container" data-tab-size="8" data-paste-markdown-skip="">

        <tbody><tr class="border-0">
          <td id="L776" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="776"></td>
          <td id="LC776" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line"> <span class="pl-k">with</span> <span class="pl-s1">self</span>.<span class="pl-en">producer_or_acquire</span>(<span class="pl-s1">producer</span>) <span class="pl-k">as</span> <span class="pl-v">P</span>: </td>
        </tr>

        <tr class="border-0">
          <td id="L777" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="777"></td>
          <td id="LC777" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">     <span class="pl-k">with</span> <span class="pl-v">P</span>.<span class="pl-s1">connection</span>.<span class="pl-en">_reraise_as_library_errors</span>(): </td>
        </tr>

        <tr class="border-0">
          <td id="L778" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="778"></td>
          <td id="LC778" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">         <span class="pl-k">if</span> <span class="pl-c1">not</span> <span class="pl-s1">ignored_result</span>: </td>
        </tr>

        <tr class="border-0">
          <td id="L779" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="779"></td>
          <td id="LC779" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">             <span class="pl-s1">self</span>.<span class="pl-s1">backend</span>.<span class="pl-en">on_task_call</span>(<span class="pl-v">P</span>, <span class="pl-s1">task_id</span>) </td>
        </tr>

        <tr class="border-0">
          <td id="L780" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="780"></td>
          <td id="LC780" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">         <span class="pl-s1">amqp</span>.<span class="pl-en">send_task_message</span>(<span class="pl-v">P</span>, <span class="pl-s1">name</span>, <span class="pl-s1">message</span>, <span class="pl-c1">**</span><span class="pl-s1">options</span>) </td>
        </tr>
    </tbody></table>
  </div>
</div>
<p></p>
<p dir="auto"></p><div class="Box Box--condensed my-2">
  <div class="Box-header f6">
    <p class="mb-0 text-bold">
      <a href="https://github.com/celery/celery/blob/bf6139bf651b20bc04b895a5f6eb8d50320bc252/celery/backends/redis.py#L342-L344">celery/celery/backends/redis.py</a>
    </p>
    <p class="mb-0 color-fg-muted">
        Lines 342 to 344
      in
      <a data-pjax="true" class="commit-tease-sha" href="/celery/celery/commit/bf6139bf651b20bc04b895a5f6eb8d50320bc252">bf6139b</a>
    </p>
  </div>
  <div itemprop="text" class="Box-body p-0 blob-wrapper blob-wrapper-embedded data">
    <table class="highlight tab-size mb-0 js-file-line-container" data-tab-size="8" data-paste-markdown-skip="">

        <tbody><tr class="border-0">
          <td id="L342" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="342"></td>
          <td id="LC342" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line"> <span class="pl-k">def</span> <span class="pl-en">on_task_call</span>(<span class="pl-s1">self</span>, <span class="pl-s1">producer</span>, <span class="pl-s1">task_id</span>): </td>
        </tr>

        <tr class="border-0">
          <td id="L343" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="343"></td>
          <td id="LC343" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">     <span class="pl-k">if</span> <span class="pl-c1">not</span> <span class="pl-en">task_join_will_block</span>(): </td>
        </tr>

        <tr class="border-0">
          <td id="L344" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="344"></td>
          <td id="LC344" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">         <span class="pl-s1">self</span>.<span class="pl-s1">result_consumer</span>.<span class="pl-en">consume_from</span>(<span class="pl-s1">task_id</span>) </td>
        </tr>
    </tbody></table>
  </div>
</div>
<p></p>
<p dir="auto"></p><div class="Box Box--condensed my-2">
  <div class="Box-header f6">
    <p class="mb-0 text-bold">
      <a href="https://github.com/celery/celery/blob/bf6139bf651b20bc04b895a5f6eb8d50320bc252/celery/backends/redis.py#L167-L177">celery/celery/backends/redis.py</a>
    </p>
    <p class="mb-0 color-fg-muted">
        Lines 167 to 177
      in
      <a data-pjax="true" class="commit-tease-sha" href="/celery/celery/commit/bf6139bf651b20bc04b895a5f6eb8d50320bc252">bf6139b</a>
    </p>
  </div>
  <div itemprop="text" class="Box-body p-0 blob-wrapper blob-wrapper-embedded data">
    <table class="highlight tab-size mb-0 js-file-line-container" data-tab-size="8" data-paste-markdown-skip="">

        <tbody><tr class="border-0">
          <td id="L167" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="167"></td>
          <td id="LC167" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line"> <span class="pl-k">def</span> <span class="pl-en">consume_from</span>(<span class="pl-s1">self</span>, <span class="pl-s1">task_id</span>): </td>
        </tr>

        <tr class="border-0">
          <td id="L168" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="168"></td>
          <td id="LC168" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">     <span class="pl-k">if</span> <span class="pl-s1">self</span>.<span class="pl-s1">_pubsub</span> <span class="pl-c1">is</span> <span class="pl-c1">None</span>: </td>
        </tr>

        <tr class="border-0">
          <td id="L169" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="169"></td>
          <td id="LC169" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">         <span class="pl-k">return</span> <span class="pl-s1">self</span>.<span class="pl-en">start</span>(<span class="pl-s1">task_id</span>) </td>
        </tr>

        <tr class="border-0">
          <td id="L170" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="170"></td>
          <td id="LC170" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">     <span class="pl-s1">self</span>.<span class="pl-en">_consume_from</span>(<span class="pl-s1">task_id</span>) </td>
        </tr>

        <tr class="border-0">
          <td id="L171" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="171"></td>
          <td id="LC171" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">  </td>
        </tr>

        <tr class="border-0">
          <td id="L172" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="172"></td>
          <td id="LC172" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line"> <span class="pl-k">def</span> <span class="pl-en">_consume_from</span>(<span class="pl-s1">self</span>, <span class="pl-s1">task_id</span>): </td>
        </tr>

        <tr class="border-0">
          <td id="L173" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="173"></td>
          <td id="LC173" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">     <span class="pl-s1">key</span> <span class="pl-c1">=</span> <span class="pl-s1">self</span>.<span class="pl-en">_get_key_for_task</span>(<span class="pl-s1">task_id</span>) </td>
        </tr>

        <tr class="border-0">
          <td id="L174" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="174"></td>
          <td id="LC174" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">     <span class="pl-k">if</span> <span class="pl-s1">key</span> <span class="pl-c1">not</span> <span class="pl-c1">in</span> <span class="pl-s1">self</span>.<span class="pl-s1">subscribed_to</span>: </td>
        </tr>

        <tr class="border-0">
          <td id="L175" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="175"></td>
          <td id="LC175" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">         <span class="pl-s1">self</span>.<span class="pl-s1">subscribed_to</span>.<span class="pl-en">add</span>(<span class="pl-s1">key</span>) </td>
        </tr>

        <tr class="border-0">
          <td id="L176" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="176"></td>
          <td id="LC176" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">         <span class="pl-k">with</span> <span class="pl-s1">self</span>.<span class="pl-en">reconnect_on_error</span>(): </td>
        </tr>

        <tr class="border-0">
          <td id="L177" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="177"></td>
          <td id="LC177" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">             <span class="pl-s1">self</span>.<span class="pl-s1">_pubsub</span>.<span class="pl-en">subscribe</span>(<span class="pl-s1">key</span>) </td>
        </tr>
    </tbody></table>
  </div>
</div>
<p></p>
<p dir="auto"></p><div class="Box Box--condensed my-2">
  <div class="Box-header f6">
    <p class="mb-0 text-bold">
      <a href="https://github.com/celery/celery/blob/bf6139bf651b20bc04b895a5f6eb8d50320bc252/celery/backends/redis.py#L124-L133">celery/celery/backends/redis.py</a>
    </p>
    <p class="mb-0 color-fg-muted">
        Lines 124 to 133
      in
      <a data-pjax="true" class="commit-tease-sha" href="/celery/celery/commit/bf6139bf651b20bc04b895a5f6eb8d50320bc252">bf6139b</a>
    </p>
  </div>
  <div itemprop="text" class="Box-body p-0 blob-wrapper blob-wrapper-embedded data">
    <table class="highlight tab-size mb-0 js-file-line-container" data-tab-size="8" data-paste-markdown-skip="">

        <tbody><tr class="border-0">
          <td id="L124" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="124"></td>
          <td id="LC124" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line"> <span class="pl-en">@<span class="pl-s1">contextmanager</span></span> </td>
        </tr>

        <tr class="border-0">
          <td id="L125" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="125"></td>
          <td id="LC125" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line"> <span class="pl-k">def</span> <span class="pl-en">reconnect_on_error</span>(<span class="pl-s1">self</span>): </td>
        </tr>

        <tr class="border-0">
          <td id="L126" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="126"></td>
          <td id="LC126" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">     <span class="pl-k">try</span>: </td>
        </tr>

        <tr class="border-0">
          <td id="L127" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="127"></td>
          <td id="LC127" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">         <span class="pl-k">yield</span> </td>
        </tr>

        <tr class="border-0">
          <td id="L128" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="128"></td>
          <td id="LC128" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">     <span class="pl-k">except</span> <span class="pl-s1">self</span>.<span class="pl-s1">_connection_errors</span>: </td>
        </tr>

        <tr class="border-0">
          <td id="L129" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="129"></td>
          <td id="LC129" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">         <span class="pl-k">try</span>: </td>
        </tr>

        <tr class="border-0">
          <td id="L130" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="130"></td>
          <td id="LC130" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">             <span class="pl-s1">self</span>.<span class="pl-en">_ensure</span>(<span class="pl-s1">self</span>.<span class="pl-s1">_reconnect_pubsub</span>, ()) </td>
        </tr>

        <tr class="border-0">
          <td id="L131" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="131"></td>
          <td id="LC131" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">         <span class="pl-k">except</span> <span class="pl-s1">self</span>.<span class="pl-s1">_connection_errors</span>: </td>
        </tr>

        <tr class="border-0">
          <td id="L132" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="132"></td>
          <td id="LC132" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">             <span class="pl-s1">logger</span>.<span class="pl-en">critical</span>(<span class="pl-v">E_RETRY_LIMIT_EXCEEDED</span>) </td>
        </tr>

        <tr class="border-0">
          <td id="L133" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="133"></td>
          <td id="LC133" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">             <span class="pl-k">raise</span> </td>
        </tr>
    </tbody></table>
  </div>
</div>
<p></p>
<p dir="auto"><code class="notranslate">_ensure</code> is set via </p><div class="Box Box--condensed my-2">
  <div class="Box-header f6">
    <p class="mb-0 text-bold">
      <a href="https://github.com/celery/celery/blob/bf6139bf651b20bc04b895a5f6eb8d50320bc252/celery/backends/redis.py#L97">celery/celery/backends/redis.py</a>
    </p>
    <p class="mb-0 color-fg-muted">
         Line 97
      in
      <a data-pjax="true" class="commit-tease-sha" href="/celery/celery/commit/bf6139bf651b20bc04b895a5f6eb8d50320bc252">bf6139b</a>
    </p>
  </div>
  <div itemprop="text" class="Box-body p-0 blob-wrapper blob-wrapper-embedded data">
    <table class="highlight tab-size mb-0 js-file-line-container" data-tab-size="8" data-paste-markdown-skip="">

        <tbody><tr class="border-0">
          <td id="L97" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="97"></td>
          <td id="LC97" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line"> <span class="pl-s1">self</span>.<span class="pl-s1">_ensure</span> <span class="pl-c1">=</span> <span class="pl-s1">self</span>.<span class="pl-s1">backend</span>.<span class="pl-s1">ensure</span> </td>
        </tr>
    </tbody></table>
  </div>
</div>
<p></p>
<p dir="auto">to be </p><div class="Box Box--condensed my-2">
  <div class="Box-header f6">
    <p class="mb-0 text-bold">
      <a href="https://github.com/celery/celery/blob/bf6139bf651b20bc04b895a5f6eb8d50320bc252/celery/backends/redis.py#L352-L358">celery/celery/backends/redis.py</a>
    </p>
    <p class="mb-0 color-fg-muted">
        Lines 352 to 358
      in
      <a data-pjax="true" class="commit-tease-sha" href="/celery/celery/commit/bf6139bf651b20bc04b895a5f6eb8d50320bc252">bf6139b</a>
    </p>
  </div>
  <div itemprop="text" class="Box-body p-0 blob-wrapper blob-wrapper-embedded data">
    <table class="highlight tab-size mb-0 js-file-line-container" data-tab-size="8" data-paste-markdown-skip="">

        <tbody><tr class="border-0">
          <td id="L352" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="352"></td>
          <td id="LC352" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line"> <span class="pl-k">def</span> <span class="pl-en">ensure</span>(<span class="pl-s1">self</span>, <span class="pl-s1">fun</span>, <span class="pl-s1">args</span>, <span class="pl-c1">**</span><span class="pl-s1">policy</span>): </td>
        </tr>

        <tr class="border-0">
          <td id="L353" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="353"></td>
          <td id="LC353" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">     <span class="pl-s1">retry_policy</span> <span class="pl-c1">=</span> <span class="pl-en">dict</span>(<span class="pl-s1">self</span>.<span class="pl-s1">retry_policy</span>, <span class="pl-c1">**</span><span class="pl-s1">policy</span>) </td>
        </tr>

        <tr class="border-0">
          <td id="L354" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="354"></td>
          <td id="LC354" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">     <span class="pl-s1">max_retries</span> <span class="pl-c1">=</span> <span class="pl-s1">retry_policy</span>.<span class="pl-en">get</span>(<span class="pl-s">'max_retries'</span>) </td>
        </tr>

        <tr class="border-0">
          <td id="L355" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="355"></td>
          <td id="LC355" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">     <span class="pl-k">return</span> <span class="pl-en">retry_over_time</span>( </td>
        </tr>

        <tr class="border-0">
          <td id="L356" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="356"></td>
          <td id="LC356" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">         <span class="pl-s1">fun</span>, <span class="pl-s1">self</span>.<span class="pl-s1">connection_errors</span>, <span class="pl-s1">args</span>, {}, </td>
        </tr>

        <tr class="border-0">
          <td id="L357" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="357"></td>
          <td id="LC357" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">         <span class="pl-en">partial</span>(<span class="pl-s1">self</span>.<span class="pl-s1">on_connection_error</span>, <span class="pl-s1">max_retries</span>), </td>
        </tr>

        <tr class="border-0">
          <td id="L358" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="358"></td>
          <td id="LC358" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">         <span class="pl-c1">**</span><span class="pl-s1">retry_policy</span>) </td>
        </tr>
    </tbody></table>
  </div>
</div>
<p></p>
<p dir="auto">But ensure is never passed any kwargs, nor is it set anywhere other than in the Backend supclass </p><div class="Box Box--condensed my-2">
  <div class="Box-header f6">
    <p class="mb-0 text-bold">
      <a href="https://github.com/celery/celery/blob/bf6139bf651b20bc04b895a5f6eb8d50320bc252/celery/backends/base.py#L106-L111">celery/celery/backends/base.py</a>
    </p>
    <p class="mb-0 color-fg-muted">
        Lines 106 to 111
      in
      <a data-pjax="true" class="commit-tease-sha" href="/celery/celery/commit/bf6139bf651b20bc04b895a5f6eb8d50320bc252">bf6139b</a>
    </p>
  </div>
  <div itemprop="text" class="Box-body p-0 blob-wrapper blob-wrapper-embedded data">
    <table class="highlight tab-size mb-0 js-file-line-container" data-tab-size="8" data-paste-markdown-skip="">

        <tbody><tr class="border-0">
          <td id="L106" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="106"></td>
          <td id="LC106" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line"> <span class="pl-s1">retry_policy</span> <span class="pl-c1">=</span> { </td>
        </tr>

        <tr class="border-0">
          <td id="L107" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="107"></td>
          <td id="LC107" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">     <span class="pl-s">'max_retries'</span>: <span class="pl-c1">20</span>, </td>
        </tr>

        <tr class="border-0">
          <td id="L108" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="108"></td>
          <td id="LC108" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">     <span class="pl-s">'interval_start'</span>: <span class="pl-c1">0</span>, </td>
        </tr>

        <tr class="border-0">
          <td id="L109" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="109"></td>
          <td id="LC109" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">     <span class="pl-s">'interval_step'</span>: <span class="pl-c1">1</span>, </td>
        </tr>

        <tr class="border-0">
          <td id="L110" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="110"></td>
          <td id="LC110" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line">     <span class="pl-s">'interval_max'</span>: <span class="pl-c1">1</span>, </td>
        </tr>

        <tr class="border-0">
          <td id="L111" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="111"></td>
          <td id="LC111" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line"> } </td>
        </tr>
    </tbody></table>
  </div>
</div>
<p></p>
<h1 dir="auto">Design</h1>
<p dir="auto">The "most obvious" way of doing this would be to add a new top-level <code class="notranslate">result_backend_options</code> config key that feeds in to the constructor.</p>
<p dir="auto">celery: 3.1.23 (Cipater)<br>
rabbitmq-server：3.2.4-1</p>
<p dir="auto">i found some task send to rabbitmq and then celery worker get duplicate task .</p>
<p dir="auto">function:<br>
def do_backup(name):<br>
....</p>
<p dir="auto">for example:<br>
server: do_backup.delay("/tmp/__36")</p>
<p dir="auto">worker02:<br>
[2016-06-23 20:38:27,182: INFO/MainProcess] Received task: tasks.do_backup[40159186-1b88-4d98-aabf-839bb4b7a852]<br>
[2016-06-23 20:38:27,183: INFO/MainProcess] tasks.do_backup[40159186-1b88-4d98-aabf-839bb4b7a852]: get file name: /tmp/__36<br>
worker12:<br>
[2016-06-23 20:36:21,647: INFO/MainProcess] Received task: tasks.do_backup[d265ffba-fa21-48b6-baad-2c0185a3168f]<br>
........<br>
[2016-06-23 20:37:01,492: INFO/MainProcess] tasks.do_backup[d265ffba-fa21-48b6-baad-2c0185a3168f]: get file name: /tmp/__36<br>
[2016-06-23 20:37:01,554: INFO/MainProcess] tasks.do_backup[d265ffba-fa21-48b6-baad-2c0185a3168f]: do task</p>
<p dir="auto">i make sure the server only send a "/tmp/__36"</p>