Friday Aug 11, 2006

Debugging with JHAT

Digging OutOfMemoryError in a Java application was very time consuming until I read about the Java Heap Analysis Tool (JHAT). JHAT is a part of jdk's forthcoming feature release Java SE 6.

I was recently tracking down OOMError and with the help of JHAT, I was quickly able to find out which class objects are a cause for this leak. With JHAT, all the objects created on the heap can be viewed in a very user friendly manner. In a nutshell, there are 2 steps by which you can analyze the heap of a java process.

- First, Dump the heap into a file. For java processes which throw OOME, you could use -XX:+HeapDumpOnOutOfMemoryError option to 'java' and the heap will dumped after the OOME from the core file it generates. For the cases, where you do not see a OOME but still want to know whats on your heap, 'jmap' or 'jconsole' can be used. These utilities dump the heap into a file.
- Secondly, you use 'jhat' utility (included in Java SE 6 kit) to create a web based interface to view your heap data from the file generated in first step. This interface provides lot of very useful information about the objects such as reference counts, weak references etc.

I was really impressed with the kind of information you get from this tool. Especially, the querying tool is very useful and innovative. This tool is must to have in the kitty for people working on Optimizations and Performance issues.

For more detailed information, visit Alan's blog.

Wednesday Jun 28, 2006

Essential Java Developer Conference - India

Kushal Foundation organized Essential Java Developer Conference on 23, 24th of June at Tata auditorium, Indian Institute of Science, Bangalore. Sun was the gold sponsor for this event.

Over the period of 2 days, the audience attended technical presentations, workshops, code camps on various Java related technologies including WebServers, Portal Servers, Open Source AppServers, Application testing and other Open source products. Sun contributed with couple of keynotes and some technical sessions. Companies like Fidelity, Mercury, Manhattan associates also featured in this event.

I presented on "Next Generation Mobile Java" on the second day of the conference. About 150 people were present and the presentation went well. The audience had limited exposure to JavaME technologies and so the stress was also on the core concepts of JavaME, with the wireless web apps development talking to web services. Most of the people in the audience, I think, were volunteered by their companies. I think, there is more evangelism to do around JavaME technologies for java developers in India.

About

user13377336

Search

Archives
« April 2014
SunMonTueWedThuFriSat
  
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
   
       
Today
Bookmarks
Blogroll

No bookmarks in folder