Environment
- WSO2 ESB 4.8.1
RabbitMQ 3.5.4
- Erlang OTP 18.0
- JDK 1.7
In this blog post I'm going to explain Integrating RabbitMQ with WSO2 ESB 4.8.1 for Message provider and consumer operations.
ESB can act as message provider to the queue and consumer from the queue. Following diagram shows provider and consumer operations
- WSO2 ESB 4.8.1
3.5.4RabbitMQ - Erlang OTP 18.0
- JDK 1.7
Diagram 1: ESB Producer/Consumer Operations |
Installing RabbitMQ
In Windows
- Download Erlang OTP from here. Installing process is automated. Double click the .exe file and follow the default instructions.
- Download RabbitMQ installer from here and install it with default settings. After finishing the server will automatically up and run.
In Linux
- Install Erlang by using the following command.
apt-get installsudo -docerlang erlang - Download RabbitMQ Generic Unix release (tar
. , from rabbitmq.com) from here.gz
Enabling the RabbitMQ management plugin
By default management GUI is disable so we have to manually enable it. Go inside the sbin folder using terminal and run the command . /rabbitmq -plugins enable rabbitmq_management
mochiweb webmachine -web-dispatchrabbitmq - amqp_client
-management-agentrabbitmq -managementrabbitmq
So now we have successfully enable the management console plugin.
To start the server, please use the command.. /rabbitmq -server
start within the sbin directory and now we can access the console using the URL http://localhost:15672/ (If you want to access the console remotely replace the localhost with the IP address)
To start the server, please use the command.
User Name - guest
Password - guest
So you can see the RabbitMQ management console like following
Diagram 2: RabbitMQ Management Console |
It's better to create new user account for future works. So go to the admin tab and create a new user with Admin tag . Click on the newly created user name and set admin permissions.
So now the RabbitMQ Server is up and running. We will see how to configure the WSO2 ESB 4.8.1 to deal with the RabbitMQ. Please follow the second part of this post.
If your server doesn't start please make sure whether following ports are free and any firewall or security application not prevent the RabbitMQ from binding to a port.
- 4369 (
), 25672 (Erlang distribution)epmd - 5672, 5671 (AMQP 0-9-1 without and with TLS)
- 15672 (if management plugin is enabled)
- 61613, 61614 (if STOMP is enabled)
- 1883, 8883 (if MQTT is enabled)
No comments :
Post a Comment