tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Remy Maucherat <r...@apache.org>
Subject Re: Call stopAwait at StandardServer.stop
Date Sun, 07 Oct 2007 21:29:47 GMT
Peter Rossbach wrote:
> can we please fix it:
> 
>     public void stop() throws LifecycleException {
> 
>         // Validate and update our current component state
>         if (!started)
>             return;
> 
>         // Notify our interested LifecycleListeners
>         lifecycle.fireLifecycleEvent(BEFORE_STOP_EVENT, null);
> 
>         lifecycle.fireLifecycleEvent(STOP_EVENT, null);
>         started = false;
> 
>         // Stop our defined Services
>         for (int i = 0; i < services.length; i++) {
>             if (services[i] instanceof Lifecycle)
>                 ((Lifecycle) services[i]).stop();
>         }
>     // ====== FIX BEGIN
>     if(port == -1)
>         stopAwait() ;
>        // ====== END
>         // Notify our interested LifecycleListeners
>         lifecycle.fireLifecycleEvent(AFTER_STOP_EVENT, null);
> 
>     }
> 
> I think we can also backport it to Tomcat 5.5 trunk

I was not aware of this feature. The change is ok, but I think the sleep 
time of the thread should also be reduced when the port is -1.

Rémy

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


Mime
View raw message