Mantis - Resin
Viewing Issue Advanced Details
878 minor always 01-19-06 09:17 01-20-06 15:07
ferg  
ferg  
high  
closed 3.0.17  
fixed  
none    
none 3.0.18  
0000878: abrupt shutdown on windows
(rep by Mark Lai)

2. Stopping Resin does not go through the WebApps stop lifecycle. The server just shuts down abruptly. So the webapps are not stopped and the servlets not destroyed. WinXP Pro task manager shows java process ended. The server is controlled using httpd.exe.
I also tried 3.0.14, which does not have this problem.
 

Notes
(0000750)
ferg   
01-20-06 08:54   
I did some digging on the abrupt server shutdown. The problem appears to be a shared data read on ResinServer's lifecycle, between the main thread and the resin-destroy thread. As soon as the resin-destory thread sets the lifecycle state to IS_DESTROYING, the main thread picks up the new state and determines that the server has been "closed". Then it exits the JVM.
By suspending the main thread during debugging, I was able to get the proper stop/destroy behavior from the resin-destroy thread.
(0000752)
ferg   
01-20-06 15:07   
Lifecycle and ResinServer needed updating to distinguish between the destroying state and the destroyed state.