Creating a Snapshot


Live charts are powerful, but you aren't always sitting with the Web Console open, waiting for your application to run out of database connections. No, that always happens at 3:00 in the morning! Other problems manifest themselves slowly, over time.

JBoss gives you the ability to capture data over regular intervals. JBoss will collect observations of a specific MBean attribute. You can start or stop the data collection process according to your needs. Then you can return later to analyze the collected values.


Note: Only numeric values can be graphed or monitored.

How do I do that?

To create a snapshot over time, choose the Create Snapshot menu item on the specific attribute you want to monitor. You'll be presented with a simple configuration form. You only need to enter the measurement time period. This is the time between measurements, in milliseconds. To monitor the value every two seconds, enter 2000 in the corresponding text field and click the Create button.

You can see the Manage Snapshot page in Figure 8-6.

To start the snapshot of memory usage, click the Start Snapshot button. Wait a few seconds for JBoss to collect measurements, and then click the Graph Dataset button. That will give you a graph like the one shown in Figure 8-7.

Developer's Notebook 8-6. Manage snapshot


Developer's Notebook 8-7. Snapshot graph


Notice that the graph isn't a live graph. It's a fixed graph of the data collected up to that point. This graph will give you a good idea of what happened over the specified time period. If you need better analysis capabilities, click Show Dataset, which displays all the collected data. You can select the data in the dataset view, and copy and paste it to an application such as Excel that can perform more sophisticated numerical analysis.



JBoss. A Developer's Notebook
JBoss: A Developers Notebook
ISBN: 0596100078
EAN: 2147483647
Year: 2003
Pages: 106

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net