The Cloud Foundry JMX Buildpack is a Cloud Native Buildpack V3 that enables the JMX in JVM applications.
Behavior
This buildpack will participate if all of the following conditions are met
$BP_JMX is set
The buildpack will do the following:
Contribute JMX configuration to $JAVA_OPTS
Configuration
Environment Variable
Description
$BP_JMX
Whether to contribute JMX support
$BPL_JMX_PORT
What port the JMX connector will listen on. Defaults to 5000.
Creating SSH Tunnel
After starting an application with JMX enabled, an SSH tunnel must be created to the container. To create that SSH container, execute the following command:
jmx-cnbThe Cloud Foundry JMX Buildpack is a Cloud Native Buildpack V3 that enables the JMX in JVM applications.
Behavior
This buildpack will participate if all of the following conditions are met
$BP_JMXis setThe buildpack will do the following:
$JAVA_OPTSConfiguration
$BP_JMX$BPL_JMX_PORT5000.Creating SSH Tunnel
After starting an application with JMX enabled, an SSH tunnel must be created to the container. To create that SSH container, execute the following command:
The
REMOTE_PORTshould match theportconfiguration for the application (5000by default). TheLOCAL_PORTmust match theREMOTE_PORT.Once the SSH tunnel has been created, your JConsole should connect to
localhost:<LOCAL_PORT>for JMX access.License
This buildpack is released under version 2.0 of the Apache License.