How to Enable ActiveMQ Web Console on ServiceMix 4.4

A few days ago I was helping an Apache user getting the ActiveMQ Web Console up and running on ServiceMix 4.4. At first instance, it seems to be a trivial setting but it's a little bit tricky.

Out of the box, every ServiceMix instance comes with an embedded ActiveMQ JMS (Java Message Service) broker. This feature makes it easy to communicate between Camel routes using persistent messages and also to distribute messages over multiple instances using clustering or load balancing.

The ActiveMQ Web Console feature is included  in any ActiveMQ distribution and you'll probably want to have it installed in ServiceMix as well to make sure you can monitor your JMS broker.

So, the first thing you have to do is to install the war feature running the following command:

karaf@root> features:install war

Then you can do run the following command to install the ActiveMQ Web Console:

karaf@root> features:install activemq-web-console 

This command will install and start the web console automatically with an embedded broker which you  can access going to the following URL: http://localhost:8181/activemqweb

But that brings the first issue... Once you have the default embedded ActiveMQ broker running then the Web Console will fail to start since it also tries to start an instance of the ActiveMQ basically on the same port number. It's quite frustrating to install a feature on ServiceMix and not be able to test it or execute it right away.

So, to configure the ActiveMQ Web Console to connect to the default embedded broker you have to do a little extra configuration change but that should be straightforward.

Go to $SMX_HOME/etc and edit the file then add the following details:


Save it and (re)start ServiceMix. That should be enough to get the ActiveMQ Web Console connected to the default embedded broker in ServiceMix.

If you don't want to monitor the default embedded broker but want to stick with the instance that the Web Console starts for you then all you will have to do is to uninstall the default embedded ActiveMQ broker with the following command:

karaf@root> features:uninstall activemq-broker 

and then restart ServiceMix. This way there will be no conflicts on the ActiveMQ port number anymore.

I hope this helps to clarify some of the issues out there...

Enjoy the ride!

Popular posts from this blog

How to Declare Variables in MS-SQL Server Management Studio

Calling Web Services with Apache Camel

Using HTTP-based endpoints with Apache Camel