RSS Feed
Download our iPhone app
Browse DevX
Sign up for e-mail newsletters from DevX


Lambda Probe Essentials: The Top 5 Features for Tomcat Administration : Page 2

Get to know Lambda Probe, an open source tool for effective and comprehensive monitoring and administration of the Tomcat application server.

Lambda Probe Essentials for Tomcat Administrators
The following are the five Lambda Probe features that every administrator in charge of monitoring and maintaining a Tomcat environment will find immediately helpful:
  • Quick Check
  • Datasource Monitoring
  • Cluster Monitoring
  • Memory Inspection
  • Session Inspection

Quick Start Administrator's Guide
For most Tomcat administrators, running out of database connections, running out of memory, or losing access to resources on the file system are daily concerns. Using Lambda Probe's Quick Check feature, administrators can:

  • Scan all available data sources and generate a maximum usage score for them.
  • Allocate one megabyte of memory into a byte array as an attempt to push the memory usage over the high watermark.
  • Create and then delete 10 files in a temporary directory.

Quick Check will report failure when:

  • At least one of the declared data sources is 100 percent used.
  • A memory allocation test (1 MB) generates an OutOfMemory exception.
  • A file-creation test encounters an IOException.

Figure 1 shows a screenshot of the results of a Quick Check scan.

Click to enlarge

Figure 1. Quick Check Results:
This is a screenshot of the results of a Quick Check scan.

While most Lambda Probe features are web based, Quick Check provides an XML version of its output for use with other automated application monitoring tools.

Datasource Monitoring
A Tomcat administrator's most serious concern is datasource pool utilization and performance. Almost all production scenarios where Tomcat is hosting web applications require database connections, and nothing brings an application down faster than non-responsive or exhausted database pools. As the number of concurrent users grows, the need for connections allocated by the connection pools grows as well.

Lambda Probe provides an intuitive datasource-monitoring feature that graphically depicts the utilization of each pooled database connection used by each application (see Figure 2). The view shows at a glance how close the utilization is to the pool's maximum, the efficiency of the applications' utilization of the connections, and other important statistics (e.g., number of used connections vs. number of busy connections).

Click to enlarge

Figure 2. Lambda Probe View of the JDBC Datasource:
Lambda Probe provides an intuitive datasource monitoring feature.

Another Lambda Probe feature that is very useful for system-availability engineering is the Group by JDBC URL option. By applying this grouping, you can easily see how many total connections are utilized for a particular database. This is especially useful information for application DBAs who can use this number to predict the maximum number of client connections allowed by the database.

Cluster Monitoring
Clustering Tomcat servers either as standalone web application containers or as embedded components of the JBoss application server is a very common production task. Clustering Tomcat servers provides higher application availability, primarily through session replication. When one instance is lost on a clustered Tomcat server, the user (given proper sessions replication) continues to interact with the application running on other instances. However, this behavior carries some performance tradeoffs that can influence the reliability of session replication:

  • Larger sessions
  • Greater number of nodes in the cluster
  • A network choke point

To help manage these tradeoffs, Lambda Probe provides very intuitive access to all the relevant information about your cluster's session-replication performance and active members. It displays information about request and replication requests (size in bytes, duration, time) in two diagrams, and displays information about cluster members (including essential statistics and clustering parameters) in an easy-to-read tabular form (see Figure 3).

Click to enlarge

Figure 3. Graphs Representing Cluster Traffic and Requests:
Lambda Probe provides access to information about your cluster.

Having this information easily accessible and effectively visualized simplifies monitoring for clustering-performance bottlenecks and expedites problem detection and diagnostics.

Memory Inspection
The dreaded OutOfMemory exception and protracted garbage collection often manifest themselves to end users as 'Page Not Found' errors, blank screens, or unacceptably long processing times. With the appropriate tools, you can detect and in some instances prevent these situations. The Java Virtual Machine (JVM) has an elaborate memory-mapping model that effectively manages the working memory dedicated to Java processes such as Tomcat.

To measure the performance of the memory-mapping process and to predict issues such as memory leaks, you need real-time access to the JVM's memory spaces data (e.g., PermGen, Survivors). Lambda Probe provides exactly that. It interacts with a VM in real time to extract and present this information in a graphical form, which in my experience is the most effective way to detect memory leak trends (see Figure 4).

Click to enlarge

Figure 4. A View of Tomcat's JVM Memory Profile:
Lambda Probe interacts with a VM in real time to extract and present this information graphically.

With access to this type of information, a Tomcat administrator has full visibility into the health and performance of the most granular aspects of a Java application. With the proper attention and investigation, no memory-related issue can remain undetected.

Session Inspection
Session inspection is a controversial subject. Sessions are pivotal web application objects that often contain sensitive user information—and therefore may not be suitable candidates for inspection. Sessions are also often the subject of serious performance concerns. Sessions that store large objects can severely restrict the scalability of an application because they linearly increase memory consumption as the number of concurrent users grows.

Finding large session-bound objects is one of the most common methods of detecting excessive memory consumption. Lambda Probe allows access to not only information about all the sessions for all applications, but it also provides access to all session objects (see Figure 5). This allows for a better understanding of whether an application is properly utilizing its session object or storing inappropriately large objects into the session (thereby reducing the memory available to other applications or to Tomcat itself).

Click to enlarge

Figure 5. Session Details with Estimated Size:
Lambda Probe interacts with a VM in real time to extract and present this information graphically.

NOTE: Lambda Probe enables administrators to destroy any session or any object within the session. Potentially, this is a highly destructive feature and I recommend extreme care.

Close Icon
Thanks for your registration, follow us on our social networks to keep up-to-date