We are building an application with a microservice architecture.
The microservice architecture will follow a message-oriented pattern, with AWS SQS.
We would like to return completion results from the consumer service back to the producer service.
This is the algorithm we are considering:
- Producer creates a message with a unique id
- Producer subscribes to a Redis channel that is named with the message id
- Producer places the message onto the queue
- Consumer removes the message from the queue and performs an operation
- Consumer publishes the results of the operation to the Redis channel that is named with the message id
- Producer recieves the completion results and resumes execution
Is this a reasonable way to pass message-completion results from a consumer back to a producer?
Aucun commentaire:
Enregistrer un commentaire