Register shutdown hook so it can tidy up a partial refresh
Previously, the shutdown hook was only registered once refresh has completed. If the JVM was shut down during refresh (or after refresh and before the hook was registered) the hook wouldn't run and the partially refreshed context would not be cleaned up. This commit moves the registration of the shutdown hook to before refresh processing begins. This ensures that the hook is available to clean up the context if the JVM is shutdown while refresh is in progress. Fixes gh-23625pull/23820/head
parent
f43970e6e0
commit
2a40bd7853
Loading…
Reference in New Issue