by codedokode · 4y ago · 0 comments
This looks like an overengineering to me, unless I have missed something. For example, I don't understand this part: "the consumer gets the message and makes a HTTP call to another web service" - why cannot that web service pull the message directly?
I would implement it like this: when a client submits a request, it is added into an SQL database, and RabbitMQ is used only to notify the consumer. The client gets back a secure Job Token that it can use for polling to get the status of the job. The consumer reads the job from the database, executes it and updates status in the database. The client uses polling to know when the job is done.
Of course, if you don't like polling, then you can use a WebSockets daemon that would notify a client when the job is done.
It could e.g. be an external service run by a third-party, or an off-the-shelf service that's hard to add integration to, etc.