java - Spring shutdown event that fires immediately before ApplicationContext is destroyed? -
i looking interceptor or trigger know that, context beans destroyed , applicationcontext instance destroy itself. can 1 process @ end of application lifetime.
there event type contextclosedevent, close thing wanna but, throws event after destruction of beans. thing comes close() method of applicationcontext. doesn't fit need
any ideas?
regards
ali
you can use registershutdownhook() method of abstract application context class. more details have @ this.
update
then should try @predestroy annotation on top of method want run in end when spring context destroy.
hope helps you. cheers.
Comments
Post a Comment