16.5. Patching Standalone Apache ActiveMQ
Abstract
AMQ provides a standalone distribution of Apache ActiveMQ (that is, Apache ActiveMQ without the Apache Karaf container) under the
InstallDir/extras
directory. Patching the standalone Apache ActiveMQ is a manual process, requiring you to copy some library files.
Patch files
The first step in patching a standalone Apache ActiveMQ instance is to figure out what patches need to be applied. When it comes to determining which patches to apply, the same principles apply as for patching the container.
See Section 16.2, “Finding the Right Patches to Apply” for details of how to work out which patches to apply and download the relevant patches.
Apache ActiveMQ install directory
For the following patching instructions, it is assumed that you have already extracted the standalone Apache ActiveMQ distribution from the
extras/apache-activemq-5.11.0.redhat-630187.zip
file and installed standalone Apache ActiveMQ into the ApacheActiveMQInstall
directory.
How to apply a patch to standalone Apache ActiveMQ
To apply a patch (or patches) to a standalone Apache ActiveMQ instance, perform the following steps:
- After determining which patches to apply, download the relevant patches from the Customer Portal, as described in Section 16.2, “Finding the Right Patches to Apply”.
- Stop the ActiveMQ broker, if it is running.
- Make a backup copy of the original standalone Apache ActiveMQ
lib
directory,ApacheActiveMQInstall/lib
- Starting with the first patch file, use an archive utility to open the downloaded patch (
.zip
) file, and extract the patch to a convenient temporary location,ExtractedPatch
. - The patched library files for the standalone Apache ActiveMQ instance are located in the following subdirectory of the patch:
ExtractedPatch/apache-activemq-5.11.0.redhat-630187/lib
Copy the complete contents of this directory to the standalone Apache ActiveMQlib
directory,ApacheActiveMQInstall/lib
. - Delete the older versions of the patched library files in
ApacheActiveMQInstall/lib
. Only one version of each library should be present in the lib directory, and it should be the patched version.For example, if you found two versions of theactivemq-broker
JAR file present in thelib
directory after copying the patch libraries:activemq-broker-5.9.0.redhat-610379.jar activemq-broker-5.9.0.redhat-611423.jar
You would delete the older version,activemq-broker-5.9.0.redhat-610379.jar
. - If you need to install a second patch on top of the first, repeat steps 4, 5, and 6, for the second patch.
- Restart the ActiveMQ broker.