Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8427481
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T04:47:36+00:00 2026-06-10T04:47:36+00:00

I have a celery task that makes a subprocess call that can only be

  • 0

I have a celery task that makes a subprocess call that can only be run parallel system-wide. While I figure out a better solution, I need to be able to execute tasks that run serially on a single worker.

I know I could create a table to track which server is currently running the task, and wait for that to finish before future tasks are run, but it seems like there must be a better way. I’ve looked pretty extensively into the celery documentation, and briefly at the rabbitmq documentation to no avail.

Has anyone out there come up with an elegant solution to this problem that hooks into some hidden features of the aforementioned technologies?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T04:47:38+00:00Added an answer on June 10, 2026 at 4:47 am

    If you setup a database cache in django that uses a database common to all servers you could implement this celery cookbook solution for executing one task at time. Instead of using a variable lock_id, just use a constant.

    In the event that the lock is not available to the worker executing the task, call retry to put the task back into the queue.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a system set up currently that is using celery with a redis
I have some periodic tasks that I run with celery (daemonized by supervisord), but
I have a view in my django project that fires off a celery task.
I've a problem with celery's logger. I have a function that renders frames. I
How can I change arguments passed to Celery programmatically? What do I have to
I have a long-running process that must run every five minutes, but more than
I have a Django project that uses Celery for running asynchronous tasks. I'm doing
I have one task that is checking a url speed, but i want that
How can I test if a task (task_id) is still processed in celery ?
Overview: I have an application that sometimes must make something with celery- and if

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.