DZone
Thanks for visiting DZone today,
Edit Profile
  • Manage Email Subscriptions
  • How to Post to DZone
  • Article Submission Guidelines
Sign Out View Profile
  • Post an Article
  • Manage My Drafts
Over 2 million developers have joined DZone.
Log In / Join
Please enter at least three characters to search
Refcards Trend Reports
Events Video Library
Refcards
Trend Reports

Events

View Events Video Library

Zones

Culture and Methodologies Agile Career Development Methodologies Team Management
Data Engineering AI/ML Big Data Data Databases IoT
Software Design and Architecture Cloud Architecture Containers Integration Microservices Performance Security
Coding Frameworks Java JavaScript Languages Tools
Testing, Deployment, and Maintenance Deployment DevOps and CI/CD Maintenance Monitoring and Observability Testing, Tools, and Frameworks
Culture and Methodologies
Agile Career Development Methodologies Team Management
Data Engineering
AI/ML Big Data Data Databases IoT
Software Design and Architecture
Cloud Architecture Containers Integration Microservices Performance Security
Coding
Frameworks Java JavaScript Languages Tools
Testing, Deployment, and Maintenance
Deployment DevOps and CI/CD Maintenance Monitoring and Observability Testing, Tools, and Frameworks

Modernize your data layer. Learn how to design cloud-native database architectures to meet the evolving demands of AI and GenAI workkloads.

Secure your stack and shape the future! Help dev teams across the globe navigate their software supply chain security challenges.

Releasing software shouldn't be stressful or risky. Learn how to leverage progressive delivery techniques to ensure safer deployments.

Avoid machine learning mistakes and boost model performance! Discover key ML patterns, anti-patterns, data strategies, and more.

Trending

  • How to Convert Between PDF and TIFF in Java
  • Start Coding With Google Cloud Workstations
  • Why I Started Using Dependency Injection in Python
  • The Role of Functional Programming in Modern Software Development

How to Configure Apache ActiveMQ on AWS

This article walks you through what Apache ActiveMQ is and includes a detailed process of configuring Apache ActiveMQ on Amazon MQ.

By 
Prashant Verma user avatar
Prashant Verma
·
Apr. 07, 22 · Tutorial
Likes (4)
Comment
Save
Tweet
Share
4.6K Views

Join the DZone community and get the full member experience.

Join For Free

Apache ActiveMQ is an open-source message broker. It is one of the most popular Apache open source products and supports multiple industry-standard connectivity protocols. Clients can choose among multiple different languages and platforms for connectivity to ActiveMQ. Apache ActiveMQ provides client libraries in C++, Python, Java, C, etc. for developing applications. Some of the most popular protocols supported by ActiveMQ are AMQP, STOMP, MQTT, and JMS. ActiveMQ supports a wide variety of messaging use cases to meet almost all the needs of a production-grade messaging system.

Amazon MQ

AWS provided Amazon MQ is a managed service that can be used for Apache ActiveMQ or RabbitMQ. Amazon MQ service makes the management, configuration, deployment, and usage of these two message brokers easy on AWS. Amazon MQ makes the lifecycle management and operation of these services easy for an IT organization as this is a fully managed service provided by AWS. Code written to connect to on-prem Apache ActiveMQ can be transparently migrated to use ActiveMQ using AWS.

Benefits of Using Amazon MQ

Easy Migration

Migrating your existing application to Amazon MQ is easy as it provides support for a wide variety of APIs and protocols such as JMS, MQTT, AMQP, WebSocket. If you have an existing application or code that uses an on-prem Apache ActiveMQ connectivity, you can easily connect to Amazon MQ using minor configuration changes.

Lessen Operational Overhead

The tasks of maintaining servers, applying patches, upgrading the OS, networking, etc. are all managed by AWS. So from an operational perspective, your organization doesn't have to deal with all the complexity and operational overhead. Security updates, software upgrades, and server and application health maintenance are all taken care of by AWS, making the development and maintenance of applications easy for the app developer.

Quality of Service

Amazon MQ provides a high throughput service that is provisioned for high availability, fault tolerance, and message durability by replicating the messages across multiple AZs (Availability Zones). This ensures the service availability even if an AZ goes offline or fails.

Configuring Apache ActiveMQ on AWS

  • Log in to the AWS console and select Amazon MQ from the list of services.

Log in to AWS Console

  • On clicking on the Amazon MQ service, a new page opens with the link to create brokers. Click on the "Get Started" icon for creating the service.

Get started icon

  • On the select broker engine page, select Apache ActiveMQ and click next. Amazon MQ provides support for Apache ActiveMQ and RabbitMQ.

Select broker engine

  • On the next page, select the deployment and storage type. In our case, we will select the "deployment mode" as a single instance broker. 
  • Deployment mode- You can select broker type to be either:
    • Single instance broker - this type of broker is available in a single AZ and is usually used for testing and development.
    • Active/standby broker - this is a configuration type that provides automatic failover and high availability. You can configure the brokers to be in separate AZs for DR scenarios and high availability.
  • Storage type
    • Durability optimized - Use this option if you want higher durability. This uses the Amazon Elastic File System for the storage of messages. In this case, messages are stored in a redundant fashion across multiple AZs. This configuration also allows for sharing the data between active and standby servers.
    • Throughput optimized - Use this option for high throughput and low latency. Data, in this case, is stored in Amazon Elastic Block Store. This configuration cannot be used with Active/Standby broker mode as it doesn't allow data accessibility from multiple servers at a time.

Select deployment and storage type

  • We will select a single-instance broker type and durability optimized storage type. Click next.

On the next page, you can input the broker name and the broker instance type. Broker instances is a list of available machine types that can be used to deploy the message broker. Depending upon the type of instance type you selected, your broker will have different configurations for network capacity, vCPUs, and memory. In this case, we will select the free tier instance type, mq.t2.micro. For authentication, you can either select simple authentication and authorization or LDAP-based authentication and authorization. Under the access tab, enter the user name and password for console access.

Other properties

Broker Engine version -  select the broker version you want to use. We selected the latest version available at this time, 5.16.3.

Broker configuration - You can either create a new configuration or reuse an existing configuration. We will create a new configuration.

CloudWatch logs - We will leave this option unselected.

Network and security - you can configure the broker to be available through a public URL or make it accessible only within the VPC.

We will use the defaults for the rest of the options such as VPC, security groups, encryption, and maintenance.

Configure settings


Additional settings

Once done, click next. On the next page, you can review and edit the selections you already made. Click  "create broker" once you are ready to create the broker. 

Create a broker

Congratulation! Your broker is getting provisioned by AWS in the background after this step. It takes approximately 20 minutes for the provisioning step to complete. Once this step is completed, you are ready to use the Apache ActiveMQ service on Amazon.

Opinions expressed by DZone contributors are their own.

Partner Resources

×

Comments
Oops! Something Went Wrong

The likes didn't load as expected. Please refresh the page and try again.

ABOUT US

  • About DZone
  • Support and feedback
  • Community research
  • Sitemap

ADVERTISE

  • Advertise with DZone

CONTRIBUTE ON DZONE

  • Article Submission Guidelines
  • Become a Contributor
  • Core Program
  • Visit the Writers' Zone

LEGAL

  • Terms of Service
  • Privacy Policy

CONTACT US

  • 3343 Perimeter Hill Drive
  • Suite 100
  • Nashville, TN 37211
  • support@dzone.com

Let's be friends:

Likes
There are no likes...yet! 👀
Be the first to like this post!
It looks like you're not logged in.
Sign in to see who liked this post!