RTView® Core
User Guide


Managing the Data Server Using JMX

The Data Server is instrumented with JMX to allow you to manage and monitor the clients and application settings, and troubleshoot an unresponsive server. To enable JMX, you must run the Data Server in socket mode and using the -jmxport command line option:

        -jmxport:(port number)

The JMX Monitor demo, located in demos\jmxmonitor in your RTView installation, shows how to use RTView to monitor the Data Server using JMX. This section describes the following MBeans on the Data Server:


RTViewDataServer:name=Manager
Use the RTViewDataServer:name=Manager MBean to manage and monitor the clients and application settings. The RTViewDataServer:name=Manager MBean has methods described in the following table.

 
Method/Attribute  Type Description
ClientData  TabularData For each client connection, the table contains the following columns.
 
Client ID - A unique number assigned by the Data Server to this client connection. The first client connection is assigned an ID of 1, the second is assigned an ID of 2, etc. The ID for an HTTP/HTTPS client will contain extra digits, starting with the ID of the Data Servlet's connection. For example, if the servlet is assigned a client ID of 1, then the first HTTP/HTTPS client will be assigned an ID of 10001, the next will be 10002, etc. ID numbers will not be reused during a Data Server session.
Address - IP address of the client. Clients running on the same host as the Data Server will display the IP address 127.0.0.1.
Host - Name of the host on which the client is running. Clients running on the same host as the Data Server will display the host name localhost. If a client's host cannot be determined, the IP address will be shown instead.
Duration - Time elapsed in this client's session with the Data Server.
Last Data Sent - Number of characters of XML data contained in this client's most recent update.
Total Data Sent - Number of characters of XML data contained in all updates during this client's session with the Data Server.
PID - The process ID of the client process. Typically, the PID column value appears as nnnn@hostname, where nnnn is the PID from the client's host system (as reported by jps, top, or tasklist) and hostname is the name of the client's host. If the client is the rtvdata or rtvquery servlet, the PID corresponds to the application server (e.g. tomcat) process on the client host. The PID column might be blank if the client is unable to obtain its PID from the local operating system. The @hostname portion might be omitted if it cannot be obtained from the local operating system.

This column is blank if the client process is running an older version of RTView that does not have this enhancement.

Process Name - This value depends on the client type. If the client is an RTView application, it is the value of the PROCESS_NAME property when the application was started. If the client process was started with a standard RTView script (run_viewer, run_displayserver, etc.) the value is viewer, builder, dataserver, displayserver or historian. For a server, a "d" at the end of the process name indicates it was started with the -daemon option. If the PROCESS_NAME property was undefined when the client process was started, then the value is RTView (the Viewer), RTView Display Builder, Display Server, Data Server or Historian, or the OEM names assigned to those applications. If the client is the viewer applet, then "applet" is appended to the name.

If the client is the rtvdata or rtvquery servlet the value is RTVDataServlet and rtvquery, respectively, or the custom servlet name that has been configured for the deployed servlet instance.

This column is blank if the client process is running an older version of RTView that does not have this enhancement.

NumberOfClients int Number of currently connected clients.
ServingData boolean True if the Data Server is currently serving data, false otherwise.
Port int The Data Server port number. The default is port 3278. This property is read-only.
PrimaryServer boolean True if the Data Server is currently the primary server in a redundant pair, false if this server is currently the backup server in a redundant pair. If the server is not in a redundant pair, the value is always true. This property is read-only.
ProxyFor string If the server is currently a backup server (that is, if PrimaryServer is false) this contains the host:port of the server that is currently the primary (to which this server forwards all client requests as a proxy). This is empty if the server is currently the primary server. This property is read-only.

The RTViewDataServer:name=Manager MBean also supports the following commands:
 
Method/Attribute Description
startServingData Start serving data.
stopServingData Stop serving data.

 


RTView:name=Troubleshooting
Use the RTView:name=Troubleshooting MBean to detect and troubleshoot an unresponsive server. The Data Server, Display Server, and Historian support the RTView:name=Troubleshooting MBean. To attach data to the MBean on an RTView display, enter RTView:name=Troubleshooting in the MBean Name field of the JMX Attach To Data dialog. To access the MBean in jconsole, select the MBeans tab, then click RTView / Troubleshooting in the tree (jconsole must be connected to the RTView server process).

The RTView:name=Troubleshooting MBean
has methods described in the following table.

Method/Attribute  Type Description
ConnectionRequestCount int The total number of socket connection requests received from clients. NOTE: The Data Server recycles unused client connection numbers if it reaches its internal limit of 10,000. This can be an issue if client applications from RTView versions prior to 5.9 attempt repeatedly to connect to the Data Server.
ConnectionRequestFailedCount int The total number of socket connection requests that failed due to a client/server software version mismatch or because the client is not an RTView client. NOTE: The Data Server recycles unused client connection numbers if it reaches its internal limit of 10,000. This can be an issue if client applications from RTView versions prior to 5.9 attempt repeatedly to connect to the Data Server.
DeadlockCount int The count of deadlocked threads. In a healthy server the count is always zero (0). This attribute is only updated every 30 seconds to reduce overhead. If JDK 1.6 is available, use the jstack utility to obtain more information about the deadlocked threads.
LastUpdateTime int The time at which the server's main update timer most recently changed. In a healthy server, this time changes on each update interval (by default, 2 seconds). If the time stops changing for an extended period, it indicates that the timer thread has stalled or terminated.
UncaughtExceptionCount int The count of uncaught exceptions since server started. In a healthy server the count is always zero (0). An uncaught exception terminates the executing thread.
UncaughtExceptions int A table of the server's uncaught exceptions listing the type, time, executing thread, and code location for each exception. (For each exception, a stack trace is also written in the server's log file).

 

 

 
SL, SL-GMS, GMS, 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-2015 Sherrill-Lubinski Corporation. All Rights Reserved.

 

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

 

Third Party Notice Requirements