I am currently trying to find out if there are any undetected or indirect dependencies among my spring beans. I was wondering if there is any way to find out the order of destruction of beans
Asked
Active
Viewed 154 times
0
-
1Does this answer your question? [Order of bean destruction in Spring context hierarchy](https://stackoverflow.com/questions/35806663/order-of-bean-destruction-in-spring-context-hierarchy) – Anish B. Sep 08 '22 at 04:44
-
Not really. There are several beans being created and implementing preDestroy for all of them might be difficult. I am looking for something similar to BeanPostProcessor but for the shutdown phase – CS1999 Sep 08 '22 at 05:00
-
1You asked the same question (more or less) 4 times over the last few days. Please stop asking the same each day. If there is no shutdown hook (predestroy etc) the bean will not be destroyed but just gc'ed. – M. Deinum Sep 08 '22 at 05:10