SPR-6354 DefaultLifecycleProcessor no longer waits for the shutdown of SmartLifecycle beans that are not actually running.

This commit is contained in:
Mark Fisher
2009-11-20 18:09:14 +00:00
parent 6653f25e81
commit c6f3613411
3 changed files with 77 additions and 0 deletions

View File

@@ -174,6 +174,10 @@ public class DefaultLifecycleProcessor implements LifecycleProcessor, BeanFactor
bean.stop();
}
}
else if (bean instanceof SmartLifecycle) {
// don't wait for beans that aren't running
latch.countDown();
}
lifecycleBeans.remove(beanName);
}
}