Tuesday, January 13, 2015

ActiveMQ 5.10.0 Installation And Configuration

Introduction

In my previous ActiveMQ introduction, I have explained the installation process, how to check what ports are used by ActiveMQ, and how to enable JMX. In this post, I am going to further explain the ports used by ActiveMQ. However the main purpose of this post to explain how to run the examples coming with ActiveMQ. This technique is important for the future discuss on how to set up high availability features with ActiveMQ, so that we can verify the configuration.

In the coming few posts, I will explain the enterprise messaging configuration for high availability with:

  1. Master-Slave HA with Share File System
  2. Use Tomcat Web Container to Host ActiveMQ Web Console
  3. Bridging the Network Broker
  4. Network Brokers
  5. Best Practices

In the future posts, I will explain java programming techniques for writing producer and consumers for java developers, as well as advanced programing for enterprise integration using Apache Camel and ActiveMQ. Thus, we will study these examples in detail.

HTT

Now first lets discuss a bit the transport connectors come with the default configuration in activemq.xml

Default Ports Used By ActiveMQ

Take a look at activemq.xml, you will find this xml segment:

        
            
            
            
            
            
            
        
All these protocols can be found at activemq.apache.org website. ActiveMQ support many other transport connectors, such as VM, SSL, NIO, NIO+SSL, HTTP, HTTPS, etc. The details can be found at http://activemq.apache.org/configuring-version-5-transports.html

Run ActiveMQ Examples

ActiveMQ comes with many examples. For easy testing, we can run the examples at examples/openwire/swissarmy. Under the dir, there is a readme file. Typically, we will use the following lines for the producer and consumers:

    ant consumer -Durl=tcp://localhost:61616 -Dtopic=true -Ddurable=true -Dmax=5000
    ant producer -Durl=tcp://localhost:61616 -Dtopic=true -DtimeToLive=30000 -Dmax=5000

Make sure ant is installed and the ANT_HOME and PATH are set properly. In the following post about ActiveMQ High Available Configuration with Master-Slave, I will cover more about how to run these examples.

No comments:

Post a Comment

Anypoint Studio Error: The project is missing Munit lIbrary to run tests

Anypoint Studio 7.9 has a bug. Even if we following the article: https://help.mulesoft.com/s/article/The-project-is-missing-MUnit-libraries-...