Overview - Queue consumers (processors)
What is it?
Queue consumers, also called processors, are parts of a NestJS application that take tasks from a queue and handle them one by one. They listen for new jobs added to the queue and run the code needed to complete those jobs. This helps your app do work in the background without making users wait. It is like having a helper who does tasks while you keep doing other things.
Why it matters
Without queue consumers, your app would have to do all tasks immediately, making users wait longer and slowing down the system. Queue consumers let your app handle many tasks smoothly by working on them separately and at the right time. This improves user experience and system reliability, especially when tasks take time or happen often.
Where it fits
Before learning queue consumers, you should understand basic NestJS concepts like modules, services, and decorators. You should also know what queues are and how to add jobs to them. After mastering consumers, you can learn advanced topics like job retries, rate limiting, and monitoring queue health.