From 078e5425cdf9a81fb0858b2dbf1dfc3ff1c74ae7 Mon Sep 17 00:00:00 2001 From: Dave Syer Date: Tue, 24 Jun 2014 14:52:38 +0100 Subject: [PATCH] Avoid eager factory bean instantiation for container customizers --- .../EmbeddedServletContainerCustomizerBeanPostProcessor.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/spring-boot/src/main/java/org/springframework/boot/context/embedded/EmbeddedServletContainerCustomizerBeanPostProcessor.java b/spring-boot/src/main/java/org/springframework/boot/context/embedded/EmbeddedServletContainerCustomizerBeanPostProcessor.java index 043fab472f..124aa26064 100644 --- a/spring-boot/src/main/java/org/springframework/boot/context/embedded/EmbeddedServletContainerCustomizerBeanPostProcessor.java +++ b/spring-boot/src/main/java/org/springframework/boot/context/embedded/EmbeddedServletContainerCustomizerBeanPostProcessor.java @@ -73,7 +73,8 @@ public class EmbeddedServletContainerCustomizerBeanPostProcessor implements // Look up does not include the parent context this.customizers = new ArrayList( this.applicationContext.getBeansOfType( - EmbeddedServletContainerCustomizer.class).values()); + EmbeddedServletContainerCustomizer.class, false, false) + .values()); Collections.sort(this.customizers, AnnotationAwareOrderComparator.INSTANCE); this.customizers = Collections.unmodifiableList(this.customizers); }