After my application finishes I want to close the spring context. The relevant code has an ApplicationContext reference but I couldn't find a close method.
ApplicationContext
close
Downcast your ApplicationContext to ConfigurableApplicationContext which defines close() method:
ConfigurableApplicationContext
close()
((ConfigurableApplicationContext)appCtx).close();
2.1m questions
2.1m answers
60 comments
57.0k users