At 07:02 PM 08/28/2001 +0530, you wrote:
>Scott,
>
>I may be wrong but here's what I think with respect to your problems:-
>
>Question 1 : - I really don't know :)

I checked in the archive again and this one I think was recently answered. 
When running apache and tomcat seperately you have to restart apache when 
you restart tomcat, or like someone else said just wait and define a nice 
friendly error page, which is a good idea.


>Question 2: - Though u have mentioned auto reload to "true" try the follwing:-
>Make a new Context entry in the Server.xml with your application and set 
>the reload value to true and see of you observations repeat. We had done a 
>similar observation and it defaults to  auto-reload=false if u don't 
>mention it explicitly ion server.xml


Tried this and it still doesnt seem to work. Unless im doing something 
wrong. I have my webapps directory, then myapp.war and the unpacked myapp 
directory If i then go somewhere else javac my one servlet and move the 
class file into webapps/myapp/WEB-INF/classes it is not auto reloaded. 
Strangely enough even after restarting tomcat i dont see my changes. I dont 
belive that though, it must be something Im doing but still i would think 
it would be simple.


>Question 3:  Tomcat's web applications are loaded using an adaptive /web 
>app class loader but it too is a class loader. So once a class is laoded 
>by the class loader it wont load it again until the class has changed( as 
>per your previous question) so removing your classes would not probably 
>affect the Classes.

Does anyone here on the list (a lurking developer maybe ) know what exactly 
what tomcat checks to determine if a class should be reloaded. Is it just 
the date time or what?


>Hope that helps
>
>Anand
>
>
>At 08:23 AM 8/28/01 -0400, you wrote:
>>         I have a question that hopefully someone on this list can help 
>> with. I use the startup.sh and shutdown.sh scripts to start and stop 
>> tomcat. If i stop tomcat and then bring it back up and go and try to 
>> view a servlet I get an internal server error from apache, like tomcat 
>> really isnt up yet or something. But if i then hit refresh on my brower 
>> like 7 or 8 times tomcat will start responding like normal. I saw a 
>> message on the same topic of this in the mail archives but I didnt see a 
>> definite answer. Anyone know why this is? And is there any way to stop this?
>>
>>Second question is about auto reloading. I use ant to create my war files 
>>so they are of the standard directory layout. After tomcat starts and 
>>unpacks the war I should be able to copy recompiled classes into the 
>>MyProject/WEB-INF/classes directory and have tomcat auto reload 
>>(server.xml says that auto reload is default to true ) This works most of 
>>the time. But sometimes i swear it wont reload my servlet until i stop 
>>tomcat, remove the unpacked war directory and restart tomcat. This 
>>doesn't make any sense to me?
>>
>>Also one last semi related question. Can someone tell me how tomcat 
>>decides what servlets to cache in memory? If it is really auto reloaded 
>>servlets, if i delete all my class files i shouldnt be able to get to any 
>>servlets correct? But i have deleted all my class files and still can get 
>>to certain servlets in my web app. So how does tomcat choose what 
>>servlets to cache or not?
>>
>>Any and all information that can help with these three questions would be 
>>greatly apprecaited. Thanks in advance.
>>
>>         Scott Knight
>

Reply via email to