|
|
|
@ -387,7 +387,7 @@ public abstract class AbstractApplicationContext extends DefaultResourceLoader |
|
|
|
else { |
|
|
|
else { |
|
|
|
applicationEvent = new PayloadApplicationEvent<>(this, event); |
|
|
|
applicationEvent = new PayloadApplicationEvent<>(this, event); |
|
|
|
if (eventType == null) { |
|
|
|
if (eventType == null) { |
|
|
|
eventType = ((PayloadApplicationEvent)applicationEvent).getResolvableType(); |
|
|
|
eventType = ((PayloadApplicationEvent) applicationEvent).getResolvableType(); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
@ -1000,11 +1000,13 @@ public abstract class AbstractApplicationContext extends DefaultResourceLoader |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
// Stop all Lifecycle beans, to avoid delays during individual destruction.
|
|
|
|
// Stop all Lifecycle beans, to avoid delays during individual destruction.
|
|
|
|
try { |
|
|
|
if (this.lifecycleProcessor != null) { |
|
|
|
getLifecycleProcessor().onClose(); |
|
|
|
try { |
|
|
|
} |
|
|
|
this.lifecycleProcessor.onClose(); |
|
|
|
catch (Throwable ex) { |
|
|
|
} |
|
|
|
logger.warn("Exception thrown from LifecycleProcessor on context close", ex); |
|
|
|
catch (Throwable ex) { |
|
|
|
|
|
|
|
logger.warn("Exception thrown from LifecycleProcessor on context close", ex); |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
// Destroy all cached singletons in the context's BeanFactory.
|
|
|
|
// Destroy all cached singletons in the context's BeanFactory.
|
|
|
|
|