Enterprise RTView® 
User Guide


Customizing the Oracle Coherence Monitor
There are several options for customizing the Oracle Coherence Monitor. The sections below describe how to customize connections, displays and security. Any files described below will need to be stored somewhere where the Oracle Coherence Monitor can access them. You should create a working directory to hold these files and run the monitor from that directory while you are working on the customization. When your customization files are ready, you must make them available to the monitor (and to the Display Server, Data Server and Historian if you will be using them). 

Adding and Modifying Connections

By default, the Oracle Coherence Monitor comes configured with two JMX connections: LocalJmxNode and RemoteJmxRMI. The LocalJmxNode connection is used when you run the monitor as the management node in your cluster. This connection should not need to be modified. The RemoteJmxRMI connection is used when you run the monitor using a remote JMX port. This connection is configured to listen to port 9991 on localhost with no authentication. Unless this is the correct host, port and authentication setting for your JMX enabled management node, you must modify the RemoteJmxRMI connection. You may also want to create additional JMX connections if you want to run multiple instances of the monitor to connect to different JMX enabled management nodes. All of the built-in displays use the $conn substitution as the connection for all data attachments. When you run the Oracle Coherence Monitor, you can specify a different connection name for the $conn substitution as follows:

run_ocmonitor -sub:$conn:MyConnection

Where MyConnection is the name of your JMX connection. NOTE: On Unix, passing a connection substitution as a command line argument requires a "\" before the '$' (e.g. -sub:\$conn...). This prevents the UNIX shell from looking in the environment for the connection variable.

The file JMXOPTIONS.ini contains all JMX connection definitions. In order to edit these connections or add new connections, run either the Display Builder or Configuration Utility from a directory containing this JMXOPTIONS.ini file. This file is packed into lib\gmsjocm.jar, so you may extract it out into your working directory, and a copy is also in demos\ocmdemo. In the Display Builder or Configuration Utility, use the JMX Connections tab to add or modify connections and Save your changes. When you save, you will be asked if you want to save to lib or to the current directory. Select the current directory. Once you save your changes, you will need to make the modified JMXOPTIONS.ini available to the monitor.

Adding Displays

The navigation tree in the Oracle Coherence Monitor contains several built-in displays, and you can also add your own displays. Use the Display Builder to build custom displays. Displays that will be shown in the main window look best if their background size is 736x544. You may attach to the JMX metrics for your cluster using the JMX data source. In order for the JMX metrics to be available to the Display Builder, you will need to use the -ocm command line option if you want to connect using a remote JMX port, or the -ocmnode command line option if you want to run as the management node in your cluster.  Add these displays to the Oracle Coherence Monitor navigation tree by creating a navigation tree definition file named custom_navtree.xml. Top level nodes from your navigation tree definition file will show up at the end of the navigation tree. Once you have created your displays and your custom_navtree.xml, you must make them available to the monitor.

See demos\ocmdemo for an example of adding custom displays to the navigation tree.

You may need to add custom functions to manipulate tables of data and perform custom transformations in your custom displays. See the Custom Functions section for information on creating custom functions for your displays.

Security

By default, the Oracle Coherence Monitor comes configured with 3 roles: demo, admin and super. See Role-Based Security for information on modifying the built-in security. The users.xml and roles.xml used by the Oracle Coherence Monitor are packed into lib\gmsjocm.jar, so you may extract them to your working directory to modify them, and a copy of these files is also in demos\ocmdemo. Once you have modified these files, you will need make them available to the monitor.

The built-in admin and super roles are used in the Administration displays to limit administration activities to users with the correct permissions. These roles should not be removed.

Using a Custom Historian Database

By default, the Enterprise RTView Historian will connect to the HSQLDB database in demos\ocmdemo. You can use any database that supports JDBC. To use a custom database, you must first set it up as your Historian database. Then add a table to your Historian database named CACHEHEALTHDATA with the following fields:
 

Field Name Field Type Recommended Field Length (if applicable)
SERVICE  Text 50
NAME Text 50
TIER  Text 50
CACHEHITS  Long Integer  
CACHEMISSES  Long Integer  
TOTALGETS Long Integer  
TOTALPUTS  Long Integer  
CACHEHITPERCENT  Double  
UNITS  Long Integer  
LOWUNITS Long Integer  
HIGHUNITS  Long Integer  
TIMESTAMP  Text 50
TIMESTAMP_LS Text 50

Run the Historian and configure it to use this database.  Save your changes. Once you save your changes, you will need to make the modified HISTORY.ini available to the monitor.

The file OPTIONS.ini contains a SQL connection named RTVHISTORY for the Historian. To edit this connection to point to your database, run either the Display Builder or Configuration Utility from a directory containing this OPTIONS.ini file. This file is packed into lib\gmsjocm.jar, so you may extract it out into your working directory, and a copy is also in demos\ocmdemo. In the Display Builder or Configuration Utility, use the SQL Connections tab to modify the RTVHISTORY connection and Save your changes. When you save, you will be asked if you want to save to lib or to the current directory. Select the current directory. Once you save your changes, you will need to make the modified OPTIONS.ini available to the monitor.

 

 

Making Customization Files Available to the Oracle Coherence Monitor

When your customization files are ready, you must make them available to the Oracle Coherence Monitor, and to the Display Server, Data Server and Historian if you will be using them. You have 3 options to do this:
  1. Run the monitor, Display Server, Data Server and Historian from your working directory. If you select this option and decide to run any of the applications from another system, you'll need to copy this directory to that system and run from there.
  2. Pack your files into a jar file named myclasses.jar. The scripts for the monitor, Display Server, Data Server and Historian will look for this jar in the startup directory and add it to the classpath. If you decide to run any of the applications from another system, you'll need to copy this jar to the startup directory there.
  3. Pack your files into a jar file by any name. Add the path to this jar file to the RTV_USERPATH environment variable on any system where you will be running the monitor, Display Server, Data Server or Historian.

If you have created a custom_navtree.xml and you will be using the Display Server, you will also need to add it to the ocmonitor.war servlet:

1. Copy custom_navtree.xml to servlets\ocmonitor.

2. In an initialized command window go to the servlets\ocmonitor directory.

3. Execute the following to rebuild ocmonitor.war:

type make_war ocmonitor

4. Use this ocmonitor.war when deploying the monitor as a thin client application.

 

 

 

 

 

 

 

 

 

 

 

 

 
SL, SL-GMS, GMS, Enterprise RTView, SL Corporation, and the SL logo are trademarks or registered trademarks of Sherrill-Lubinski Corporation in the United States and other countries. Copyright © 1998-2008 Sherrill-Lubinski Corporation. All Rights Reserved.

 
JMS, JMX and Java are trademarks and/or registered trademarks of Sun Microsystems, Inc. in the United States and other countries. They are mentioned in this document for identification purposes only.