How to monitor Fisheye Crucible using JMX in Linux

Still need help?

The Atlassian Community is here for you.

Ask the community

Purpose

See real time operating data from your Fisheye/Crucible instance. For example, if you want to determine the number of repositories open in memory monitor the activeCount variable.

Other variables:

Attribute name

Values

PassivationStats

NameFunction
activeCacheSizeCurrent total size of the cache for all active repos
activeCountTotal number of active (i.e. in-memory) runnable repositories
cacheUsageFractional usage of the allocated cache
gcPassivationsTotal number of passivations due to GC load
maxActivePassivationsCurrent count of passivations due to reaching the active limit
maxActiveReposMaximum number of active repos allowed
maxCacheSizeMax total heap size allocated to per-repo caches, in bytes
needingPassivationCacheSizeCurrent total size of the cache for all close-wait repos
needingPassivationCountTotal number of active (i.e. in-memory) repositories requiring passivation
perRepoCacheSizeCurrent per-repo cache size setting in bytes
runnableCountTotal number of repositories considered runnable

What is JMX?

JMX (Java Management eXtensions) is a technology for monitoring and managing Java applications. JMX uses objects called MBeans (Managed Beans) to expose data and resources from your application.


Solution

The JMX interface allows you to see live internal information from your Fisheye/Crucible instance, via the following MBean:

com.atlassian.fisheye.rep.PassivateMXBean

Enable JMX in Fisheye/Crucible

Add the following options to your FISHEYE_OPTS environment variable and restart Fisheye/Crucible:


-Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=8061 -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Djava.rmi.server.hostname=<FishEye server FQDN>

Using a JMX Client

You need to use a JMX client in order to view the JMX output from Confluence. JConsole is a readily available JMX client that is included with the supported Java Developer Kit (version 5 onwards).

  1. Open JConsole and select Remote Process
  2. Specify the hostname of server and the port that JMX is running on, ie. fisheyeserver.company.com:8061
  3. Click Connect
  4. When prompted, click the Insecure button


Adding live monitoring to a production instance may have an impact on performance.


Enable Jetty JMX MBeans

In case you want to extend the monitoring to Jetty and enable JMX for the Jetty MBeans it is possible to add one extra parameter to the FISHEYE_OPTS environment variable to enable that:

-Dfisheye.jetty.jmx.enable=true

The full content of the FISHEYE_OPTS in this case will be the following:

-Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=8061 -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Djava.rmi.server.hostname=<FishEye server FQDN> -Dfisheye.jetty.jmx.enable=true


If this option is enabled, at restart, Fisheye/Crucible will show the following extra log line:

2018-03-12 10:50:02,963 INFO  - System property fisheye.jetty.jmx.enable set to value: true



When enabled you will see extra MBean available in your JMX client. Below an example of the MBean available on VisualVM:




Last modified on Nov 2, 2018

Was this helpful?

Yes
No
Provide feedback about this article
Powered by Confluence and Scroll Viewport.