Berkeley DB Java Edition
JConsole Plugin

Overview

The BDB JE JConsole plugins let you monitor running JE applications using the jconsole utility which is distributed with the JDK. Two plugins are provided: one for monitoring non-HA JE applications (JE_HOME/lib/JEJConsole.jar), and another for monitoring JE HA applications (JE_HOME/lib/RepJEJConsole.jar). The former allows jconsole to monitor and display EnvironmentStats and the latter shows both EnvironmentStats and ReplicatedEnvironmentStats.

The plugins can:

The JEJConsole.jar can be used to monitor both JE non-HA and JE HA applications. In the latter case it will not show the "JE Replicated Statistics" tab shown in the second screen shot above. See the javadoc for EnvironmentStats and ReplicatedEnvironmentStats for more information about the meaning of the statistics.

Here are two sample screen shots of jconsole running the two plugins.

With the JEJConsole.jar plugin:



With the RepJEJConsole.jar plugin:

Using The Plugins

jconsole can only monitor applications that have registered a DynamicMBean. Both JE and JE HA will automatically register an appropriate DynamicMBean when an Environment or ReplicatedEnvironment is created, if the JEMonitor system property is set to true (e.g. using -DJEMonitor=true on the command line).

To use the JE and JE Replication plugins, invoke jconsole with the -pluginpath option to specify one of the libraries. For example:

    jconsole -pluginpath JE_HOME/lib/JEJConsole.jar

or

    jconsole -pluginpath JE_HOME/lib/RepJEJConsole.jar

When the plugin starts up, a menu will appear which lets you choose the process to monitor. Your JE application should appear if you have set -DJEMonitor=true. There is a known problem with discovering Java processes on Windows platforms when the temporary directory is on a FAT type file system. In that case, a Java application may need to set -XX:+PerfBypassFileSystemCheck on the Java command line in order for the process to appear on the connection menu.

After connecting to the process, a "JE Statistics" tab will be shown in jconsole. The tab will be named "JE Replicated Statistics" when using the RepJEJConsole.jar plugin. The tab provides various options:

Please report bugs to the Berkeley DB Java Edition OTN forum.