For better performance, the Servlets will be loaded by Tomcat when the servlets are first called. You can optionally switch on the "runtime reload" by the config files. Please check "debug" of the <Context> option

解决方案 »

  1.   

    我所使用的版本是tomcat4.0.1
    平台是win2000+sp2+IIS
    使用j2se1.4
      

  2.   

    use "rutime reload“???how to use it?
    我不知道debug使用哪个值可以实现你所说的runtime reload。
    我照它原来那样写的是debug=0,应该使用什么value,可以实现你所说的功能?
      

  3.   

    from tomcat 4 documentset the attribute "reloadable" instead of "debug", sorry Set to true if you want Catalina to monitor classes in /WEB-INF/classes/ and /WEB-INF/lib for changes, and automatically reload the web application if a change is detected. This feature is very useful during application development, but it requires significant runtime overhead and is not recommended for use on deployed production applications. You can use the Manager web application, however, to trigger reloads of deployed applications on demand.
      

  4.   

    在conf目录下的server.xml中加入你的Context,把reloadable属性设为true:
    <Context path="..." docBase="..." debug="..." reloadable="true">
    ...
    </Context>
      

  5.   

    also, you may need to call reload by http://localhost:8080/manager/reload?path=/examplesSignal an existing application to shut itself down and reload. This can be useful when you've recompiled classes on an application that is not configured with the reloadable="true" attribute in its <Context> entry in $CATALINA_HOME/conf/server.xml, or when you've made other changes (such as to conf/web.xml) that are not automatically recognized by Tomcat.If this command succeeds, you will see a response like this:   
     OK - Reloaded application at context path /examples
      

  6.   

    jim的方法和有效,确实可以了,谢谢大家的帮助。那么tomcat是否自己就带有WebServer的,如果我不用IIS,就装个TOMCAT也就可以用于WebServer的?
      

  7.   

    cosomo所说的,在发布时候,不要有reloadable,
    是不是用了这个的话,会增加TOMCAT的负担,使得它的性能下降?
    现在哪个这种WebServer上面运行Servlet和JSP最快,而且对机器要求也比叫低,消耗资源少?
      

  8.   

    tomcat自己带有WebServer, but use apache + tomcat is more stable and scalable
      

  9.   

    resin我以前也试过的,确实比较方便,那时觉得
    不过也没怎么研究过,这种东西太多了
    我看书上介绍,好象是推荐用Application server来用里面的web container