Jan Giacomelli
Celery on AWS ECS - the art of background tasks & continuous deployment
#1about 2 minutes
Understanding the role of background tasks in applications
Background tasks are essential for handling long-running processes, scheduled jobs like newsletters, and operations that require retries without blocking the user.
#2about 3 minutes
Choosing Celery and AWS ECS with Fargate for your stack
Celery is the most widely used Python task queue, and AWS ECS with Fargate provides a serverless, scalable environment for running workers without managing servers.
#3about 2 minutes
Key AWS ECS settings for reliable Celery workers
Configure a long stop timeout (120 seconds) and set minimum healthy percent to 50% to give workers time to shut down gracefully during deployments.
#4about 3 minutes
Handling interruptions from continuous deployment and scaling
Frequent deployments and auto-scaling actions on ECS interrupt running tasks, which can prevent long-running jobs from ever completing and risk task loss.
#5about 10 minutes
Configuring Celery for task reliability and visibility
Set `task_acks_late`, `task_reject_on_worker_lost`, a short `visibility_timeout`, and a `prefetch_multiplier` of one to prevent task loss and duplication.
#6about 3 minutes
Remapping SIGTERM to SIGQUIT for immediate cold shutdowns
Use the `BILLIARD_REMAP_SIGTERM` environment variable to remap the SIGTERM signal to trigger a cold shutdown, ensuring interrupted tasks are immediately re-queued.
#7about 3 minutes
Designing tasks to be short-lived and idempotent
Design tasks to be idempotent and aim for a maximum processing time under 15 minutes to reduce the impact of interruptions and ensure reliable execution.
#8about 7 minutes
Using fan-out and batching patterns to manage long workloads
Break down large jobs using the fan-out pattern for parallel processing or the batching pattern for sequential, interruptible processing of smaller chunks.
#9about 3 minutes
Using Redis for task locking to prevent duplicate execution
Implement a locking mechanism using Redis to ensure that only one worker can process a specific task at a time, preventing race conditions and duplicate work.
#10about 4 minutes
Reviewing code examples for fan-out, batching, and locking
A walkthrough of Python code demonstrates how to implement the fan-out, batching, and Redis-based locking patterns for robust Celery tasks.
#11about 16 minutes
Answering common questions about Celery on AWS
Discussion on topics including the generality of interruption problems, collecting logs from killed workers, and finding additional learning resources for Celery and AWS.
Related jobs
Jobs that call for the skills explored in this talk.
envelio
Köln, Germany
Remote
Senior
Python
Software Architecture
Matching moments
01:32 MIN
Organizing a developer conference for 15,000 attendees
Cat Herding with Lions and Tigers - Christian Heilmann
02:44 MIN
Rapid-fire thoughts on the future of work
What 2025 Taught Us: A Year-End Special with Hung Lee
02:54 MIN
Automating video post-production with local scripts
Cat Herding with Lions and Tigers - Christian Heilmann
03:17 MIN
Selecting strategic partners and essential event tools
Cat Herding with Lions and Tigers - Christian Heilmann
04:57 MIN
Increasing the value of talk recordings post-event
Cat Herding with Lions and Tigers - Christian Heilmann
04:22 MIN
Why HR struggles with technology implementation and adoption
What 2025 Taught Us: A Year-End Special with Hung Lee
04:27 MIN
Moving beyond headcount to solve business problems
What 2025 Taught Us: A Year-End Special with Hung Lee
09:16 MIN
Actionable tips for employers and employees
Sustainable High Performance: Build It or Pay the Price
Featured Partners
Related Videos
Single Server, Global Reach: Running a Worldwide Marketplace on Bare Metal in a Cloud-Dominated World
Jens Happe
Containers in the cloud - State of the Art in 2022
Federico Fregosi
CD2CF - Continuous Deployment to Cloud Foundry
Dominik Kress
Serverless: Past, Present and Future
Oliver Arafat
Cloud-nativeApplications- What’s the buzz about
Jens Eickmeyer
Python-Based Data Streaming Pipelines Within Minutes
Bobur Umurzokov
Practical tips and tricks for CI/CD success
Zan Markan
Serverless on Cloud
Cheng Zhang
Related Articles
View all articles



From learning to earning
Jobs that call for the skills explored in this talk.




Climax.eco
Rotterdam, Netherlands
€70-100K
Senior
TypeScript
PostgreSQL
Cloud (AWS/Google/Azure)

Celonis
Edinburgh, United Kingdom
Remote
Senior
Python
Data analysis
Machine Learning

Celonis
München, Germany
Senior
API
Azure
Kafka
DevOps
Python
+11



GW Active
Guildford, United Kingdom
£41K
PHP
GIT
REST
Scrum
+6