You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by alik alikov <al...@rambler.ru.INVALID> on 2022/12/12 04:40:03 UTC
Tomcat 9.0.65 Failed stop jpf application in shell mode
When I try to shut down the application in the IDE console by 'q' application doesn't stopped.
Thread Dump in attachments.
Console log:
dec 08, 2022 12:59:21 PM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["http-nio2-8080"]
dec 08, 2022 12:59:21 PM org.apache.tomcat.util.net.Nio2Endpoint bind
WARNING: The NIO2 connector requires an exclusive executor to operate properly on shutdown
dec 08, 2022 12:59:48 PM org.apache.catalina.core.StandardService startInternal
INFO: Starting service [Tomcat]
dec 08, 2022 12:59:48 PM org.apache.catalina.core.StandardEngine startInternal
INFO: Starting Servlet engine: [Apache Tomcat/9.0.65]
dec 08, 2022 12:59:48 PM org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["http-nio2-8080"]
dec 08, 2022 12:59:49 PM org.apache.catalina.startup.ContextConfig getDefaultWebXmlFragment
INFO: No global web.xml found
application started in SHELL mode
Press 'q' key to exit.
q
dec 08, 2022 1:18:18 PM org.apache.coyote.AbstractProtocol pause
INFO: Pausing ProtocolHandler ["http-nio2-8080"]
dec 08, 2022 1:18:18 PM org.apache.catalina.core.StandardService stopInternal
INFO: Stopping service [Tomcat]
dec 08, 2022 1:18:18 PM org.apache.coyote.AbstractProtocol stop
INFO: Stopping ProtocolHandler ["http-nio2-8080"] I think this happens because we use http nio2 protocol, and we personally create an executor for him.
private void configureExecutor(final Connector connector, final String connectorName) { final StandardThreadExecutor executor = new TomcatThreadExecutor(); executor.setName(connectorName); final AbstractProtocol<?> protocol = (AbstractProtocol<?>) connector.getProtocolHandler(); String namePrefix = protocol.getName(); namePrefix = namePrefix.substring(1, namePrefix.length() - 1); executor.setNamePrefix(namePrefix + "-exec-"); executor.setMaxThreads(protocol.getMaxThreads()); executor.setMinSpareThreads(protocol.getMinSpareThreads()); tomcat.getEngine().getService().addExecutor(executor); protocol.setExecutor(executor); }
.
RE: Tomcat 9.0.65 Failed stop jpf application in shell mode
Posted by alik alikov <al...@rambler.ru.INVALID>.
Thanks a lot it's work
12.12.2022, 11:00, Mark Thomas < mailto:markt@apache.org markt@apache.org >
On 12/12/2022 04:40, alik alikov wrote: > When I try to shut down the application in the IDE console by 'q' application doesn't stopped. > > Thread Dump in attachments. > > Console log: > > dec 08, 2022 12:59:21 PM org.apache.coyote.AbstractProtocol init > INFO: Initializing ProtocolHandler ["http-nio2-8080"] > dec 08, 2022 12:59:21 PM org.apache.tomcat.util.net.Nio2Endpoint bind > WARNING: The NIO2 connector requires an exclusive executor to operate properly on shutdown You can avoid this if you let the NIO2 connector use the built-in executor rather than defining a (potentially) shared, external executor. > dec 08, 2022 12:59:48 PM org.apache.catalina.core.StandardService startInternal > INFO: Starting service [Tomcat] > dec 08, 2022 12:59:48 PM org.apache.catalina.core.StandardEngine startInternal > INFO: Starting Servlet engine: [Apache Tomcat/9.0.65] > dec 08, 2022 12:59:48 PM org.apache.coyote.AbstractProtocol start > INFO: Starting ProtocolHandler ["http-nio2-8080"] > dec 08, 2022 12:59:49 PM org.apache.catalina.startup.ContextConfig getDefaultWebXmlFragment > INFO: No global web.xml found > application started in SHELL mode > Press 'q' key to exit. > q > dec 08, 2022 1:18:18 PM org.apache.coyote.AbstractProtocol pause > INFO: Pausing ProtocolHandler ["http-nio2-8080"] > dec 08, 2022 1:18:18 PM org.apache.catalina.core.StandardService stopInternal > INFO: Stopping service [Tomcat] > dec 08, 2022 1:18:18 PM org.apache.coyote.AbstractProtocol stop > INFO: Stopping ProtocolHandler ["http-nio2-8080"] > > I think this happens because we use http nio2 protocol, and we personally create an executor for him. Using an external executor triggers the warning above. It has nothing to do with why Tomcat doesn't shutdown. The thread dump shows that the utility executor hasn't shut down. That means that the Server object hasn't been shutdown correctly. Server.stop() has been called but Server.destroy() also needs to be called. Mark --------------------------------------------------------------------- To unsubscribe, e-mail: /compose/ users-unsubscribe@tomcat.apache.org For additional commands, e-mail: /compose/ users-help@tomcat.apache.org
RE: Tomcat 9.0.65 Failed stop jpf application in shell mode
Posted by alik alikov <al...@rambler.ru.INVALID>.
Okay thank you I'll try it
12.12.2022, 11:00, Mark Thomas < mailto:markt@apache.org markt@apache.org >
On 12/12/2022 04:40, alik alikov wrote: > When I try to shut down the application in the IDE console by 'q' application doesn't stopped. > > Thread Dump in attachments. > > Console log: > > dec 08, 2022 12:59:21 PM org.apache.coyote.AbstractProtocol init > INFO: Initializing ProtocolHandler ["http-nio2-8080"] > dec 08, 2022 12:59:21 PM org.apache.tomcat.util.net.Nio2Endpoint bind > WARNING: The NIO2 connector requires an exclusive executor to operate properly on shutdown You can avoid this if you let the NIO2 connector use the built-in executor rather than defining a (potentially) shared, external executor. > dec 08, 2022 12:59:48 PM org.apache.catalina.core.StandardService startInternal > INFO: Starting service [Tomcat] > dec 08, 2022 12:59:48 PM org.apache.catalina.core.StandardEngine startInternal > INFO: Starting Servlet engine: [Apache Tomcat/9.0.65] > dec 08, 2022 12:59:48 PM org.apache.coyote.AbstractProtocol start > INFO: Starting ProtocolHandler ["http-nio2-8080"] > dec 08, 2022 12:59:49 PM org.apache.catalina.startup.ContextConfig getDefaultWebXmlFragment > INFO: No global web.xml found > application started in SHELL mode > Press 'q' key to exit. > q > dec 08, 2022 1:18:18 PM org.apache.coyote.AbstractProtocol pause > INFO: Pausing ProtocolHandler ["http-nio2-8080"] > dec 08, 2022 1:18:18 PM org.apache.catalina.core.StandardService stopInternal > INFO: Stopping service [Tomcat] > dec 08, 2022 1:18:18 PM org.apache.coyote.AbstractProtocol stop > INFO: Stopping ProtocolHandler ["http-nio2-8080"] > > I think this happens because we use http nio2 protocol, and we personally create an executor for him. Using an external executor triggers the warning above. It has nothing to do with why Tomcat doesn't shutdown. The thread dump shows that the utility executor hasn't shut down. That means that the Server object hasn't been shutdown correctly. Server.stop() has been called but Server.destroy() also needs to be called. Mark --------------------------------------------------------------------- To unsubscribe, e-mail: /compose/ users-unsubscribe@tomcat.apache.org For additional commands, e-mail: /compose/ users-help@tomcat.apache.org
Re: Tomcat 9.0.65 Failed stop jpf application in shell mode
Posted by Mark Thomas <ma...@apache.org>.
On 12/12/2022 04:40, alik alikov wrote:
> When I try to shut down the application in the IDE console by 'q' application doesn't stopped.
>
> Thread Dump in attachments.
>
> Console log:
>
> dec 08, 2022 12:59:21 PM org.apache.coyote.AbstractProtocol init
> INFO: Initializing ProtocolHandler ["http-nio2-8080"]
> dec 08, 2022 12:59:21 PM org.apache.tomcat.util.net.Nio2Endpoint bind
> WARNING: The NIO2 connector requires an exclusive executor to operate properly on shutdown
You can avoid this if you let the NIO2 connector use the built-in
executor rather than defining a (potentially) shared, external executor.
> dec 08, 2022 12:59:48 PM org.apache.catalina.core.StandardService startInternal
> INFO: Starting service [Tomcat]
> dec 08, 2022 12:59:48 PM org.apache.catalina.core.StandardEngine startInternal
> INFO: Starting Servlet engine: [Apache Tomcat/9.0.65]
> dec 08, 2022 12:59:48 PM org.apache.coyote.AbstractProtocol start
> INFO: Starting ProtocolHandler ["http-nio2-8080"]
> dec 08, 2022 12:59:49 PM org.apache.catalina.startup.ContextConfig getDefaultWebXmlFragment
> INFO: No global web.xml found
> application started in SHELL mode
> Press 'q' key to exit.
> q
> dec 08, 2022 1:18:18 PM org.apache.coyote.AbstractProtocol pause
> INFO: Pausing ProtocolHandler ["http-nio2-8080"]
> dec 08, 2022 1:18:18 PM org.apache.catalina.core.StandardService stopInternal
> INFO: Stopping service [Tomcat]
> dec 08, 2022 1:18:18 PM org.apache.coyote.AbstractProtocol stop
> INFO: Stopping ProtocolHandler ["http-nio2-8080"]
>
> I think this happens because we use http nio2 protocol, and we personally create an executor for him.
Using an external executor triggers the warning above. It has nothing to
do with why Tomcat doesn't shutdown.
The thread dump shows that the utility executor hasn't shut down. That
means that the Server object hasn't been shutdown correctly.
Server.stop() has been called but Server.destroy() also needs to be called.
Mark
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org