Category Archives: debug

Signs and Portents

It has been a very long time since my first post.

Most of the work I’ve been doing on the Kato project has been on the Early Draft Review of  JSR-326 (available here: JSR-326).

More interestingly, in IBM here we’ve had a summer student (Paul Sobek – I don’t have a link to him) writing a JVMTI agent in C that dumps all sorts of Java goodness. Our problem was with hprof there wasn’t quite enough information for our needs, and the information is offered was limited. Using  his agent it is now possible to inspect local variables at the time a dump was taken.

Ultimately, we’d like this to be our Reference Implementation, after much more testing against our TCK and implementation of non-JVM information (such as the machine’s hostname). In combination with our JDI connector, it is possible to attach a Java debugger to the dump files and determine what caused them.

Would this be something you want? For example, take a long running server. If an ArrayIndexOutOfBounds exception is thrown, then either the JVM will exit, or it will be caught and ignored. Using this agent, a dump could be taken automatically, and offline it could be debugged.

Soon I hope to write here how you can try this out for yourself…