tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "David Rees" <dr...@greenhydrant.com>
Subject Re: Losing line numbers in stracktraces
Date Wed, 07 Apr 2004 00:36:52 GMT
Hans Verschoor wrote:
>
> I have a problem reading stacktrace info when Tomcat throws an exception
> caused by a servlet or a class calld by a servlet
> I have my classes compiled into in the ..... WEB-INF/classes directory and
> (so far) I use no war or jar.
> When an exception is thrown the stacktrace does not show line numbers but
> "Unknown source", which is "not so handy".
> The classes are compiled correctly, in other circumstances the line
> numbers DO appear in stacktraces using the same classes.
> I am a relative newbie, so my questions are:
> 1. Do I need to configure the webapploader explicitly ?
> 2. Do I need some switch on de java statement when starting tomcat ?

Make sure you compile your classes with the -g flag to javac.  Otherwise,
line numbers will be optimized out.

-Dave

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-dev-help@jakarta.apache.org


Mime
View raw message