Monitoring BlazeDS and LCDS applications

Not sure how many people know about this but most of BlazeDS/LCDS server classes are exposed as JMX MBeans which means they can be viewed with a JMX enabled client such as jconsole. Additionally, BlazeDS/LCDS comes with a simple application called ds-console that can be used to view these MBeans as well. These MBeans provide information about the state of the server such as number of Flex Sessions, number of Flex Clients, command counts, message counts, along with some performance related info. If you want to check it out yourself, here’s what you need to do.

First, you need to make sure manageable flag is set to true in services-config.xml (by default, it’s enabled). This makes sure MBeans are created and exposed via JMX server. You can turn off management if you don’t want your application to be available via JMX or for other reasons (eg. Goggle App Engine does not support JMX for example).

Then, you can start your application along with ds-console application. Ds-console has a few tabs but I think the “Generic Administration View” is the most useful one. It shows all the exposed MBeans in a tree like structure:

DSConsole application.

You don’t actually need ds-console to see these MBeans. You can use jconsole that comes with Java. Setup is pretty easy. As you first start your server, you need to make sure JMX is enabled. You can do this in a number of ways but one easy way to set the following Java option in the terminal and start the server.

export JAVA_OPTS=-Dcom.sun.management.jmxremote

Then, simply start jconsole from the terminal and attach to your server. You should see the same tree view in jconsole:

JConsole application
JConsole application
Advertisements

One thought on “Monitoring BlazeDS and LCDS applications

  1. This is a great entry. Do we have any third party softwares which provides the statistical analysis of the LCDS application performance and especially Messaging monitoring(Message performance headers is the one i know provided by LCDS itself).

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s