# Plotly Dash parallel background callback

**URL:** <https://community.plotly.com/t/plotly-dash-parallel-background-callback/88552>\
**Category:** Dash Python\
**Tags:** question\
**Created:** [November 7, 2024, 7:55pm UTC](https://community.plotly.com/t/plotly-dash-parallel-background-callback/88552 "2024-11-07T19:55:09Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![fabbasi](https://avatars.discourse-cdn.com/v4/letter/f/76d3ee/32.png) [@fabbasi](https://community.plotly.com/u/fabbasi)\
**Post date:** [November 7, 2024, 7:55pm UTC](https://community.plotly.com/t/plotly-dash-parallel-background-callback/88552/1 "2024-11-07T19:55:09Z")

</div>

I want to have a dash background callback function that runs a lengthy python function once a file is uploaded. Will dash accept a new callback trigger on the input for another run on say a different file even though the same callback is still in progress on another set of inputs?  
In other word can you trigger the same background callback on multiple inputs.

---

<div class="post-metadata">

**Author:** ![AIMPED](https://sea2.discourse-cdn.com/flex024/user_avatar/community.plotly.com/aimped/32/21758_2.png) [@AIMPED](https://community.plotly.com/u/AIMPED)\
**Post date:** [November 8, 2024, 6:21am UTC](https://community.plotly.com/t/plotly-dash-parallel-background-callback/88552/2 "2024-11-08T06:21:37Z")

</div>

@fabbasi are you referring to a queuing of callbacks?

---

<div class="post-metadata">

**Author:** ![Emil](https://sea2.discourse-cdn.com/flex024/user_avatar/community.plotly.com/emil/32/31734_2.png) [@Emil](https://community.plotly.com/u/Emil)\
**Post date:** [November 10, 2024, 12:10pm UTC](https://community.plotly.com/t/plotly-dash-parallel-background-callback/88552/3 "2024-11-10T12:10:00Z")

</div>

I believe that the standard behavior is to cancel the running callback, and start the new one instead.

---

<div class="post-metadata">

**Author:** ![fabbasi](https://avatars.discourse-cdn.com/v4/letter/f/76d3ee/32.png) [@fabbasi](https://community.plotly.com/u/fabbasi)\
**Post date:** [November 13, 2024, 7:30pm UTC](https://community.plotly.com/t/plotly-dash-parallel-background-callback/88552/4 "2024-11-13T19:30:22Z")

</div>

I think what I am looking for is parallel background callbacks…will it queue or can dash have parallel long callbacks that are independent of each other. I think I need to find a running example to see what Dash is capable of doing

---

<div class="post-metadata">

**Author:** ![Emil](https://sea2.discourse-cdn.com/flex024/user_avatar/community.plotly.com/emil/32/31734_2.png) [@Emil](https://community.plotly.com/u/Emil)\
**Post date:** [November 13, 2024, 9:03pm UTC](https://community.plotly.com/t/plotly-dash-parallel-background-callback/88552/5 "2024-11-13T21:03:50Z")

</div>

That’s not how Dash works. Dash is a UI framework, it sounds like you are looking for an (async) job queue. You can use e.g. Celery with Dash, which I believe would support your use case.
