Last active
July 28, 2022 18:43
-
-
Save nzpr/5a07ac8085972546509eedb7a1f9809f to your computer and use it in GitHub Desktop.
RaabbitMQ server with curl. Setup and use.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1. To spin up an instance of rabbitMQ: `docker run -d -it --rm --name rabbitmq -p 5672:5672 -p 15672:15672 rabbitmq:3.9-management` | |
2. Open port 5672 to allow API calls. | |
3. To be able to access management GUI publish port 15672, by default management server is binded to localhost. It is accessible via web browser. | |
4. Use web GUI or https://www.rabbitmq.com/management-cli.html to manage exchanges, queues, topics from CLI. | |
5. The zero dependency way to talk to rabbitMQ after exchanges and queues are created is to use HTTP API via curl. | |
https://rawcdn.githack.com/rabbitmq/rabbitmq-server/v3.10.6/deps/rabbitmq_management/priv/www/api/index.html | |
https://dev.to/valanto/sending-a-rabbitmq-message-with-json-payload-using-curl-3l4k | |
Also various clients are available https://github.com/rabbitmq/rabbitmq-tutorials | |
So to sum up. | |
Start docker image. Open ports 5672 (and 15672 if you wish to use GUI). Create exchange and queues. Try publish data. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment