Using ActiveMQ connection pools (Advanced)
In this recipe we will take a look at ActiveMQ's connection pooling library and see how using it in your applications can increase performance and reduce the load placed on your broker.
Getting ready
For this recipe, we will use the example application named connection-pools to demonstrate the use of the ActiveMQ pooling library. Before proceeding, you should ensure that there are no other broker instances running on your computer since our example uses the embedded broker trick we learned previously.
How to do it...
To run the sample for this recipe, open a terminal, change the path to the directory where connection-pools is located, and run it by typing mvn compile exec:java
.
In the terminal where you started ...
Get Instant Apache ActiveMQ Messaging Application Development How-to now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.