Java profiling

Here are some steps taken from the sun/oracle docs on troubleshooting and profiling Java apps

Get the memory usage and garbage colletion statistics;

Obtain a Heap histogram;