Solved

Springframework shutdown in tomcat don't work

Posted on 2006-06-16
6
668 Views
Last Modified: 2013-11-24
Hi everyone,

I'm using the <bean ... init-method="connect" destroy-method="disconnect"> feature in applicationcontext.xml.
While the init-method gets called the destroy method gets not touched if TOMCAT shuts down.
The framework works fine! Just this feature don't work.
Are there any other settings (except the web.xml       <listener><listener-class>org.springframework.web.context.ContextLoaderListener</listener-class></listener>  entry ) needed, to force the springframework to receive the shutdown event from tomcat?

Thanks for the help!

Frank

0
Comment
Question by:hefter1
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
6 Comments
 
LVL 92

Accepted Solution

by:
objects earned 500 total points
ID: 16919685
That gets called when the context gets shutdown, is the context getting shut down when tomcat does?
0
 

Author Comment

by:hefter1
ID: 16919825
Hi objects,

I just get a
***This server has been successfully shutdown***
message, nothing else. I'm using Eclipse with MyEclipse plugin to control tomcat.
Maybe I should add a log.xml entry for the spring container?

Frank
0
 

Author Comment

by:hefter1
ID: 16919916
I can't see that the context shuts down in debug mode.
How else could I see that?
0
Revamp Your Training Process

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action.

 

Author Comment

by:hefter1
ID: 16919935
I tried to implement  DisposableBean - no effect! Even this method gets not called!! So the container has no control!?
The beans I'm using are singletons by default.
0
 

Author Comment

by:hefter1
ID: 16920050
Found the reason: If I call it as a service everything works fine. It seems that the MyEclipse plugin don't call the shutdown. Grrrrr.
0
 

Author Comment

by:hefter1
ID: 16932686
In the meantime I got response from MyEclipse. They will fix that in upcoming Version 5 in july 2006.
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction This article is the second of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article covers the basic installation and configuration of the test automation tools used by…
International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
Viewers will learn about the different types of variables in Java and how to declare them. Decide the type of variable desired: Put the keyword corresponding to the type of variable in front of the variable name: Use the equal sign to assign a v…
This theoretical tutorial explains exceptions, reasons for exceptions, different categories of exception and exception hierarchy.

617 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question