activemq-artemis/examples/features/standard/jmx-ssl
Justin Bertram 88c686cc99 [maven-release-plugin] prepare release 2.9.0 2019-05-29 21:59:18 -05:00
..
src/main ARTEMIS-2087 fix NPE; mask password in example 2018-09-26 09:20:24 -04:00
pom.xml [maven-release-plugin] prepare release 2.9.0 2019-05-29 21:59:18 -05:00
readme.md NO-JIRA fix-up examples 2018-03-01 14:58:56 -06:00

readme.md

JMX Management Example

To run the example, simply type mvn verify from this directory, or mvn -PnoServer verify if you want to start and create the broker manually.

This example shows how to manage ActiveMQ Artemis using JMX over SSL

Example configuration

ActiveMQ Artemis exposes its managed resources by default on the platform MBeanServer.

To access this MBeanServer remotely, add the following to the management.xml configuration:

<connector connector-port="1099" connector-host="localhost"/>

With these properties, ActiveMQ Artemis broker will be manageable remotely using standard JMX URL on port 1099.

The various keystore files are generated using the following commands:

  • keytool -genkey -keystore server-side-keystore.jks -storepass secureexample -keypass secureexample -dname "CN=ActiveMQ Artemis Server, OU=Artemis, O=ActiveMQ, L=AMQ, S=AMQ, C=AMQ" -keyalg RSA
  • keytool -export -keystore server-side-keystore.jks -file server-side-cert.cer -storepass secureexample
  • keytool -import -keystore client-side-truststore.jks -file server-side-cert.cer -storepass secureexample -keypass secureexample -noprompt
  • keytool -genkey -keystore client-side-keystore.jks -storepass secureexample -keypass secureexample -dname "CN=ActiveMQ Artemis Client, OU=Artemis, O=ActiveMQ, L=AMQ, S=AMQ, C=AMQ" -keyalg RSA
  • keytool -export -keystore client-side-keystore.jks -file client-side-cert.cer -storepass secureexample
  • keytool -import -keystore server-side-truststore.jks -file client-side-cert.cer -storepass secureexample -keypass secureexample -noprompt

More information