Trampoline Systems

* Trampoline Description Here

Trampoline Systems

* Trampoline Description Here


Content

Machines

Ideas, thoughts and observations from Trampoline's technical brains

Archive for October, 2006

mccraig

java stack trace annotation

By craig mcmillan on October 24th, 2006

i’ve just spent an age tracking down a problem parsing an xml file with commons digester. it turned out to be because someone had missed an element out of the hierarchy, and digester was trying to call a method which didn’t exist because of that

tracking down the problem took ages because there is no information in java stack traces other than a list of method calls. if each method called had an ability to annotate the current stack frame with some application related information [ the name or path of the xml element currently being processed in this case ], then i wouldn’t have needed to fire up the debugger and manually correlate the stack trace with objects in the debugger

all that would be needed would be some method like :

Thread.annotateStackTrace(String)