Detect controller methods via InitializingBean hook
Previously RequestMappingHandlerMapping detected @RequestMapping
methods through an initApplicationContext() hook. However, the
HandlerMapping may not have been fully set up with all its
dependencies at that point including settings like useSuffixPattern
and others.
This change moves the detection @RequestMapping methods to an
InitializingBean.afterPropertiesSet() hook.
Issue: SPR-9371
@ -72,7 +73,7 @@ public abstract class AbstractHandlerMethodMapping<T> extends AbstractHandlerMap
@@ -72,7 +73,7 @@ public abstract class AbstractHandlerMethodMapping<T> extends AbstractHandlerMap
@ -81,11 +82,17 @@ public abstract class AbstractHandlerMethodMapping<T> extends AbstractHandlerMap
@@ -81,11 +82,17 @@ public abstract class AbstractHandlerMethodMapping<T> extends AbstractHandlerMap
@ -99,7 +106,7 @@ public abstract class AbstractHandlerMethodMapping<T> extends AbstractHandlerMap
@@ -99,7 +106,7 @@ public abstract class AbstractHandlerMethodMapping<T> extends AbstractHandlerMap
if(logger.isDebugEnabled()){
logger.debug("Looking for request mappings in application context: "+getApplicationContext());
@ -131,17 +138,17 @@ public abstract class AbstractHandlerMethodMapping<T> extends AbstractHandlerMap
@@ -131,17 +138,17 @@ public abstract class AbstractHandlerMethodMapping<T> extends AbstractHandlerMap
@ -149,7 +156,7 @@ public abstract class AbstractHandlerMethodMapping<T> extends AbstractHandlerMap
@@ -149,7 +156,7 @@ public abstract class AbstractHandlerMethodMapping<T> extends AbstractHandlerMap
@ -161,11 +168,11 @@ public abstract class AbstractHandlerMethodMapping<T> extends AbstractHandlerMap
@@ -161,11 +168,11 @@ public abstract class AbstractHandlerMethodMapping<T> extends AbstractHandlerMap
@ -177,19 +184,19 @@ public abstract class AbstractHandlerMethodMapping<T> extends AbstractHandlerMap
@@ -177,19 +184,19 @@ public abstract class AbstractHandlerMethodMapping<T> extends AbstractHandlerMap
@ -199,7 +206,7 @@ public abstract class AbstractHandlerMethodMapping<T> extends AbstractHandlerMap
@@ -199,7 +206,7 @@ public abstract class AbstractHandlerMethodMapping<T> extends AbstractHandlerMap
@ -230,11 +237,11 @@ public abstract class AbstractHandlerMethodMapping<T> extends AbstractHandlerMap
@@ -230,11 +237,11 @@ public abstract class AbstractHandlerMethodMapping<T> extends AbstractHandlerMap
@ -289,7 +296,7 @@ public abstract class AbstractHandlerMethodMapping<T> extends AbstractHandlerMap
@@ -289,7 +296,7 @@ public abstract class AbstractHandlerMethodMapping<T> extends AbstractHandlerMap
@ -308,7 +315,7 @@ public abstract class AbstractHandlerMethodMapping<T> extends AbstractHandlerMap
@@ -308,7 +315,7 @@ public abstract class AbstractHandlerMethodMapping<T> extends AbstractHandlerMap
@ -360,5 +367,5 @@ public abstract class AbstractHandlerMethodMapping<T> extends AbstractHandlerMap
@@ -360,5 +367,5 @@ public abstract class AbstractHandlerMethodMapping<T> extends AbstractHandlerMap