I am new to RabbitMQ and I have a few doubts about its usage.
I was reading the RabbitMQ documentation and found this line.
The main idea behind Work Queues (aka: Task Queues) is to avoid doing a resource-intensive task immediately and having to wait for it to complete.
... like images to be resized or pdf files to be rendered.
My question is if I have an application for Image resizing.
- Can/Should I pass the Image (as bytes) to the queue then process it? (Which I think is bad) or
- Should I pass the location of the image as a message to the queue and read from the db then process it?
Apart from that
- How are message queues useful in implementing CQRS pattern. and
- Where else message queues are useful in an application.
Thank you.
Aucun commentaire:
Enregistrer un commentaire