Our great sponsors
-
WorkOS
The modern identity platform for B2B SaaS. The APIs are flexible and easy-to-use, supporting authentication, user identity, and complex enterprise features like SSO and SCIM provisioning.
Most of the tutorials that I see to use rabbitmq with go are using amps (like this). That is all fine and dandy, but I still could not find any tutorial on how to integrate the amps consumer output to http handler? I guess I should get the consumer output through a middleware but have difficulty on how to do so.
You need to implement a WebSocket connection then broadcast the notification that comes from rabbitmq. https://github.com/gorilla/websocket works well and I've used it for some tooling and small API's. Make it stateful with websocket compared to stateless with REST