tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Cathy Ooi" <>
Subject Class partially reloaded even after restarting Tomcat
Date Thu, 25 Oct 2001 08:16:49 GMT

I don't know if anyone have come across this ...

I'm running a Tomcat-3.3-m4, with Apache 1.3 on Red Hat Linux release 7.0.
My JVM is Classic VM (build 1.3.0, J2RE 1.3.0 IBM build cx130-20010329 (JIT
enabled: jitc)).

I have 2 JSP pages menu.jsp and data.jsp that called a class DBManager that in
turn uses DBConfig that contains final static variables e.g. DBConfig.DB_URL.

Originally, DBConfig.DB_URL = "".
Called http://testserver/menu.jsp.
And I get an Exception "java.lang.Exception: Cannot connect to MySQL server on". Perfectly okay, since "" is the wrong value.

So I modified to the correct value, DBConfig.DB_URL = "".
Compile & upload DBConfig.class again.
Remove the generated files in "work".
Shutdown & start up tomcat again.
Called http://testserver/menu.jsp again. And I get an Exception
"java.lang.Exception: Cannot connect to MySQL server on" again!
But when I called http://testserver/data.jsp, the page was displayed correctly
with the data retrieved from the DB.

I've tried stopping & restarting both tomcat & apache several times but the
result remains the same. I've even 'pstree -ap' to check that all tomcat
processes has terminated. But the old value stubbornly remains after several
shutdowns & startups.

Finally, my colleague shutdown tomcat and waited about 30 minutes before
starting up tomcat again. (Previously, there's a few seconds interval between
shutdown and startup) This time, menu.jsp works correctly.

Is there anywhere tomcat might have cached the class or value?
Is there a faster way to get the static final value reloaded?

Thanks in advance.


p.s. There are 2 other J2SE applications running in the same server, but I don't
think this should matter since they're both running in different processes,

Do You Yahoo!?
Get your free address at

View raw message