problems with workers in django app

I have a problem with the workers, after days they go offline, then I restart my app and they are online again
Solution:
then this is an issue with the code or config, please add better logging so you can narrow down by the worker is exiting
Jump to solution
17 Replies
Percy
Percy3mo ago
Project ID: N/A
Brody
Brody3mo ago
are there any error logs?
javieraraya5573
javieraraya55733mo ago
nope the last log 24-07-08 15:06:56,299: WARNING/ForkPoolWorker-5] Producto MLC1499816993 está under_review. [2024-07-08 15:06:56,302: WARNING/ForkPoolWorker-4] Updated link ID 8387: Order ID MK23PDMNF8 to status approved. [2024-07-08 15:06:56,526: WARNING/ForkPoolWorker-4] Updated link ID 4616: Order ID MK7KS80RR4 to status approved. [2024-07-08 15:06:56,604: WARNING/ForkPoolWorker-5] Updated link ID 6998: Order ID MKJB96Y8N5 to status approved. [2024-07-08 15:06:56,831: WARNING/ForkPoolWorker-4] Updated link ID 4583: Order ID MKX6TE3O4R to status approved. [2024-07-08 15:06:57,236: WARNING/ForkPoolWorker-5] Updated link ID 7679: Order ID MK4X5X2RQL to status approved. [2024-07-08 15:06:57,243: WARNING/ForkPoolWorker-4] Updated link ID 4662: Order ID MKQZ0CAP1G to status approved. Stopping Container I put this in settings CELERY_BROKER_URL = os.environ["REDIS_URL"] CELERY_RESULT_BACKEND = os.environ["REDIS_URL"] CELERY_ACCEPT_CONTENT = ['json'] CELERY_TASK_SERIALIZER = 'json' CELERY_RESULT_SERIALIZER = 'json' CELERY_TIMEZONE = 'UTC' CELERY_WORKER_MAX_TASKS_PER_CHILD = 100 # Reiniciar el worker después de 100 tareas CELERY_TASK_ACKS_LATE = True # Acknowledge las tareas tarde para evitar la pérdida de tareas CELERY_WORKER_PREFETCH_MULTIPLIER = 1 # Controlar la cantidad de tareas que un worker puede prefetchear CELERY_TASK_TIME_LIMIT = 3600 # Limitar el tiempo de ejecución de una tarea a 1 hora but i dont know if its necesary
Brody
Brody3mo ago
what do the memory metrics look like
javieraraya5573
javieraraya55733mo ago
Network egress only has a big pick
Brody
Brody3mo ago
I'm sorry but that doesn't answer the question
javieraraya5573
javieraraya55733mo ago
and Disk usage
No description
javieraraya5573
javieraraya55733mo ago
No description
javieraraya5573
javieraraya55733mo ago
hi?
Brody
Brody3mo ago
since upgrading to the hobby plan have you redeployed the worker service?
javieraraya5573
javieraraya55733mo ago
how do I do that
Brody
Brody3mo ago
has the service for your worker redeployed since you have upgraded to the hobby plan
javieraraya5573
javieraraya55733mo ago
yes mm I think so because i use github so in the week I am up changes commits so when i put a new commits all the services are redeploying
Solution
Brody
Brody3mo ago
then this is an issue with the code or config, please add better logging so you can narrow down by the worker is exiting
javieraraya5573
javieraraya55733mo ago
mm how i do that
Want results from more Discord servers?
Add your server