History | Log In     View a printable version of the current page.  
Issue Details (XML | Word | Printable)

Key: IDEADEV-12812
Type: Bug Bug
Status: Open Open
Priority: Normal Normal
Assignee: Nikolay Chashnikov
Reporter: Thomas Singer
Votes: 7
Watchers: 4
Operations

If you were logged in you would be able to see more operations.
IDEA: Development

Can't stop Tomcat 5.5.12 correctly

Created: 19 Dec 06 00:08   Updated: 27 Sep 07 23:32
Component/s: J2EE.Deployment and Run.Tomcat
Fix Version/s: None

Original Estimate: Unknown Remaining Estimate: Unknown Time Spent: Unknown
Issue Links:
Duplicate
 
This issue is duplicated by:
IDEA-10934 VM Detach from Tomcat not recognized ... Closed
IDEA-9462 Shutdown tomcat error Closed

Build: 6,137
Severity: High


 Description  « Hide
When I press the red square button (Stop) in the Run|Tomcat view, it prints
Last packet sent to the server was 0 ms ago.
cmd /c C:\jdk1.5.0_08\bin\java "-Dcatalina.base=C:\Dokumente und Einstellungen\tom\.IntelliJIdea60\system\tomcat_Tomcat_caa32f441" "-Dcatalina.home=C:\Tomcat 5.5.12" "-Djava.io.tmpdir=C:\Tomcat 5.5.12\temp" -jar "C:\Tomcat 5.5.12\bin\bootstrap.jar" stop
18.12.2006 22:01:48 org.apache.coyote.http11.Http11BaseProtocol pause
INFO: Pausing Coyote HTTP/1.1 on http-8080
18.12.2006 22:01:49 org.apache.catalina.core.StandardService stop
INFO: Stopping service Catalina
18.12.2006 22:01:49 org.apache.coyote.http11.Http11BaseProtocol destroy
INFO: Stopping Coyote HTTP/1.1 on http-8080
18.12.2006 22:01:49 org.apache.catalina.core.AprLifecycleListener lifecycleEvent
INFO: Failed shutdown of Apache Portable Runtime
Disconnected from server

but the "Rerun Tomcat" icon is not enabled any more. Clicking the red cross (Close) button shows a message "Process 'Tomcat' is running/Disconnect from the progress 'Tomcat'?". Leaving the checkbox "Terminate the process after disconnect" unselected and clicking the Disconnect button shows a progress dialog "Terminating 'Tomcat'/Waiting for VM detach". Only when clicking the Cancel button, the Run|Tomcat view disappears and can be relaunched successfully.

I have this problem for a long time with a lot of IDEA versions.



 All   Comments   Work Log   Change History      Sort Order:
Thomas Singer - 13 Jan 07 18:55
More information: we have a non-deamon-timer running.

Jeff Melby - 18 Jan 07 01:40
I was also having this problem and reported it--closed as duplicate for this JIRA. I found after investigating that our application was not properly shutting down a concurrent thread pool we use. In Intellij 6, it actually seems to be a feature (not a bug) that it recognizes that the process has not shut down properly, even though the main catalina thread had shut down from tomcat, and the log showed it was disconnected from server. A stray java process was still running, though no longer listening to port 8080, so we never noticed it before. I suspect Intellij 5 and earlier was only checking for the catalina process. Non-daemon timers also need to be stopped on application shutdown, so I suspect that is your problem.

Thomas Singer - 18 Jan 07 11:20
Yes, Jeff, this is the technical explanation. Nevertheless, when I stop the Tomcat-run-configuration, I want IDEA to stop the whole launched process. When launching an ordinary desktop application, stopping it also stops the process, no matter what thread-types were launched.