In this article, we will outline the step to setup and configure Amazon Web Services (AWS) ELB for use with RabbitMQ.
In most situations if you have a RabbitMQ cluster you should have a load balancer in front of it so you have 1 known IP (DNS) address, AWS provide this via the ELB.
Some general steps to setting up the ELB are:
1. Under the AWS console select EC2 and then create an ELB.
2. Create a LB for the VPC
3. Set the ports that need to be redirected i.e.
- 5672 - TCP - RabbitMQ port
- 15672 - HTTP - management Web GUI
4. Add any security required to the 2 ports
5. Set up health check on 5672 (see Image 1.1)
6. Add your EC2 instances to the ELB (see Image 1.2 - note only one EC2 in this screenshot, but you can add more). Also "Cross-Zone Load Balancing distributes traffic evenly across all your back-end instances in all Availability Zones."
7. Test it out by using the ELB URL
We have some documentations on AWS here: https://www.rabbitmq.com/ec2.html