JMX Monitoring

Top  Previous  Next

You can monitor many aspects of the Code Collaborator server via JMX, Java's standard, built-in network monitoring system.

Setting up a basic JMX system

To enable JMX you must add Java properties to the server startup script.  To do that, edit the file ccollab-server.vmoptions which is found inside the server installation directory.

Inside this file, add the following lines:

-Dcom.sun.management.jmxremote=true

-Dcom.sun.management.jmxremote.port=54321

-Dcom.sun.management.jmxremote.authenticate=false

-Dcom.sun.management.jmxremote.ssl=false

 

The first line enables JMX.  The second line sets the TCP/IP port number for the JMX protocol, and of course you can use a value other than the example 54321.  The last two lines disable JMX authentication and security.

Note: You must restart the Code Collaborator server before these settings take effect.

You can now use any JMX console software to access the Code Collaborator JMX variables.  Sun's Java installation ships with a simple JMX console which can be found in [Java-Install-Dir]/bin/jconsole.exe.  If you use Sun's console, select the "Remote" tab in the connection dialog and specify the host name, the port given in the configuration above.  Leave "User Name" and "Password" blank.

Supported JMX data

There are various things you can monitor with JMX, and this manual cannot cover them all.

The data specific to Code Collaborator can be found under "MBeans," then under the root tree node "com.smartbear.ccollab."  Under there you will find one child tree node for each installation of Code Collaborator, named by the web page it's installed under.  The default is just a simple forward slash.  Under that node is various data.

Of particular note is "ApplicationStateCache" and "ServletState."  This contains basic information about logins, licensing, versioning, and product usage.

More complex JMX server configurations

A full description of how to configure JMX is outside the scope of this manual.  It is completely standardized and documented on Sun's web site.  A good resource to get you started is this:

http://java.sun.com/j2se/1.5.0/docs/guide/management/agent.html