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
Refcards Trend Reports Events Over 2 million developers have joined DZone. Join Today! Thanks for visiting DZone today,
Edit Profile Manage Email Subscriptions Moderation Admin Console How to Post to DZone Article Submission Guidelines
View Profile
Sign Out
Refcards
Trend Reports
Events
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

Apache ActiveMQ 5.9: One of the Strongest ActiveMQ Releases

Claus Ibsen user avatar by
Claus Ibsen
·
Oct. 23, 13 · Interview
Like (0)
Save
Tweet
Share
14.28K Views

Join the DZone community and get the full member experience.

Join For Free

The Apache ActiveMQ team has just released ActiveMQ 5.9.

Apache ActiveMQ 5.9 released
It's been 8 months of hard work since the previous 5.8 release.  I'll get right to the new features.

In this release, we have hardened the broker and added new protocols such as AMQP and MQTT.  We've also hardened the LevelDB persistent store, which now includes a new replication functionality.

Over time, we plan to make LevelDB the default persistent store out-of-box, replacing the current KahaDB store. But that will come in a future release.

Another extremely helpful new feature is the ability to do runtime configuration changes to the broker without having to restart the broker. You cannot change everything without a restart just yet, but you can, for example, update network connectors when you have clustered brokers, etc. The new documentation will show you which things can be updated without a restart.

For the Camel users, there is a new broker component that allows lighter inter-broker routing. Rob Davies has previously blogged about this and provides an interesting use case that uses Camel routing logic to decide if a message should go into one queue or to another depending on the current queue depth.

Last but not least, Apache ActiveMQ now ships with Hawt.io as its new web console out of the box. The old web console is still there, but it is considered deprecated.

We also cleaned up in the conf directory, moving all the example configurations into examples/conf.

Apache ActiveMQ 5.9 release notes are here.

Starting Apache ActiveMQ

To try out Apache ActiveMQ you go to the activemq.apache.org web site and click the download link. Then you can download a zip or tgz file of the distribution. Then you unzip/untar the file and then you can start the broker from the command line as shown below:
davsclaus:/opt$ tar xf ~/Downloads/apache-activemq-5.9.0-bin.tar.gz
davsclaus:/opt$ cd apache-activemq-5.9.0/
davsclaus:/opt/apache-activemq-5.9.0$ bin/activemq console
When the broker is staring up it now logs all the transport connectors it provides and their urls.
From the logs below we can see that ...
 INFO | Listening for connections at: tcp://davsclaus.air:61616?maximumConnections=1000&wireFormat.maxFrameSize=104857600
 INFO | Connector openwire started
 INFO | Listening for connections at: amqp://davsclaus.air:5672?maximumConnections=1000&wireFormat.maxFrameSize=104857600
 INFO | Connector amqp started
 INFO | Listening for connections at: stomp://davsclaus.air:61613?maximumConnections=1000&wireFormat.maxFrameSize=104857600
 INFO | Connector stomp started
 INFO | Listening for connections at: mqtt://davsclaus.air:1883?maximumConnections=1000&wireFormat.maxFrameSize=104857600
 INFO | Connector mqtt started
 INFO | Listening for connections at ws://davsclaus.air:61614?maximumConnections=1000&wireFormat.maxFrameSize=104857600
 INFO | Connector ws started
we have the following transport connections enabled

  • openwire - is the JMS protocol
  • amqp - AMQP 1.0
  • stomp - is a very simple text based protocol that you can use from telnet 
  • mqtt - for machine to machine communication
  • ws - WebSocket (stomp or mqtt)

Telnet to the Broker

For example, with STOMP we can connect to the broker using telnet, and type in the telnet shell STOMP commands to connect and then send and receive messages. To connect I can type
telnet localhost 61613
CONNECT
login:foo
passcode:bar

^@
And the broker will respond with:
CONNECTED
heart-beat:0,0
session:ID:davsclaus.air-61798-1382433481104-2:1
server:ActiveMQ/5.9.0
version:1.0
And I can then disconnect with:
DISCONNECT

^@
Connection closed by foreign host.
There is a user guide here how to use telnet with stomp.

Accessing the Web Console

When the ActiveMQ broker starts up, it logs the URL for the web console(s)
 INFO | ActiveMQ WebConsole available at http://localhost:8161/

So just open a broker on that link. When you access the console, it's secured, so you need to login. The broker comes with a default user and password, which you can see in the conf/users.properties file.

There is also a docs/WebConsole-README.txt file that provides more details about the web consoles, and how you can turn on/off login.

With the Hawt.io web console, we can create queues and send messages to the queues. In the screenshot below I have created two queues: beer and wine, and I've told it to send a message to the beer.
Hawt.io web console - Comes out of the box in the new Apache ActiveMQ 5.9 release.
The console has actions to move messages between queues, browse, and delete. And messages in dead letter queues can be resubmitted to their original queue, which allows it to retry processing the message(s).


Trying the ActiveMQ Web Examples

Apache ActiveMQ comes with a few web examples you can try by starting the broker like so:
bin/activemq console xbean:examples/conf/activemq-demo.xml
Try the examples, then open the web browser at http://localhost:8161/ and click on the last link. You should also try clicking on the web console link (Hawt.io) because the web console now shows the Camel plugin as one of the examples using Camel.

Hope this release gives you a lot more power in what you can do with your applications!

Apache ActiveMQ Release (agency) Console (video game CLI)

Opinions expressed by DZone contributors are their own.

Popular on DZone

  • Differences Between Site Reliability Engineer vs. Software Engineer vs. Cloud Engineer vs. DevOps Engineer
  • Mr. Over, the Engineer [Comic]
  • Deploying Java Serverless Functions as AWS Lambda
  • Upgrade Guide To Spring Data Elasticsearch 5.0

Comments

Partner Resources

X

ABOUT US

  • About DZone
  • Send feedback
  • Careers
  • Sitemap

ADVERTISE

  • Advertise with DZone

CONTRIBUTE ON DZONE

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

LEGAL

  • Terms of Service
  • Privacy Policy

CONTACT US

  • 600 Park Offices Drive
  • Suite 300
  • Durham, NC 27709
  • support@dzone.com
  • +1 (919) 678-0300

Let's be friends: