Buggy code:
public class RequestMappingHandlerAdapter extends AbstractHandlerMethodAdapter implements BeanFactoryAware , InitializingBean { private List < HandlerMethodArgumentResolver > customArgumentResolvers ; private List < HandlerMethodReturnValueHandler > customReturnValueHandlers ; private List < ModelAndViewResolver > modelAndViewResolvers ; private List < HttpMessageConverter < ? > > messageConverters ; private WebBindingInitializer webBindingInitializer ; private int cacheSecondsForSessionAttributeHandlers = 0 ; private boolean synchronizeOnSession = false ; private ParameterNameDiscoverer parameterNameDiscoverer = new LocalVariableTableParameterNameDiscoverer ( ) ; private ConfigurableBeanFactory beanFactory ; private SessionAttributeStore sessionAttributeStore = new DefaultSessionAttributeStore ( ) ; private boolean ignoreDefaultModelOnRedirect = false ; private final Map < Class < ? > , SessionAttributesHandler > sessionAttributesHandlerCache = new ConcurrentHashMap < Class < ? > , SessionAttributesHandler > ( ) ; private HandlerMethodArgumentResolverComposite argumentResolvers ; private HandlerMethodArgumentResolverComposite initBinderArgumentResolvers ; private HandlerMethodReturnValueHandlerComposite returnValueHandlers ; private final Map < Class < ? > , Set < Method > > initBinderCache = new ConcurrentHashMap < Class < ? > , Set < Method > > ( ) ; private final Map < ControllerAdviceBean , Set < Method > > initBinderAdviceCache = new LinkedHashMap < ControllerAdviceBean , Set < Method > > ( ) ; private final Map < Class < ? > , Set < Method > > modelAttributeCache = new ConcurrentHashMap < Class < ? > , Set < Method > > ( ) ; private final Map < ControllerAdviceBean , Set < Method > > modelAttributeAdviceCache = new LinkedHashMap < ControllerAdviceBean , Set < Method > > ( ) ; private AsyncTaskExecutor taskExecutor = new SimpleAsyncTaskExecutor ( "MvcAsync" ) ; private Long asyncRequestTimeout ; private ContentNegotiationManager contentNegotiationManager = new ContentNegotiationManager ( ) ; public RequestMappingHandlerAdapter ( ) { } public void setCustomArgumentResolvers ( List < HandlerMethodArgumentResolver > argumentResolvers ) { } public List < HandlerMethodArgumentResolver > getCustomArgumentResolvers ( ) { } public void setArgumentResolvers ( List < HandlerMethodArgumentResolver > argumentResolvers ) { } public HandlerMethodArgumentResolverComposite getArgumentResolvers ( ) { } public void setInitBinderArgumentResolvers ( List < HandlerMethodArgumentResolver > argumentResolvers ) { } public HandlerMethodArgumentResolverComposite getInitBinderArgumentResolvers ( ) { } public void setCustomReturnValueHandlers ( List < HandlerMethodReturnValueHandler > returnValueHandlers ) { } public List < HandlerMethodReturnValueHandler > getCustomReturnValueHandlers ( ) { } public void setReturnValueHandlers ( List < HandlerMethodReturnValueHandler > returnValueHandlers ) { } public HandlerMethodReturnValueHandlerComposite getReturnValueHandlers ( ) { } public void setModelAndViewResolvers ( List < ModelAndViewResolver > modelAndViewResolvers ) { } public List < ModelAndViewResolver > getModelAndViewResolvers ( ) { } public void setMessageConverters ( List < HttpMessageConverter < ? > > messageConverters ) { } public List < HttpMessageConverter < ? > > getMessageConverters ( ) { } public void setWebBindingInitializer ( WebBindingInitializer webBindingInitializer ) { } public WebBindingInitializer getWebBindingInitializer ( ) { } public void setSessionAttributeStore ( SessionAttributeStore sessionAttributeStore ) { } public void setCacheSecondsForSessionAttributeHandlers ( int cacheSecondsForSessionAttributeHandlers ) { } public void setSynchronizeOnSession ( boolean synchronizeOnSession ) { } public void setParameterNameDiscoverer ( ParameterNameDiscoverer parameterNameDiscoverer ) { } public void setIgnoreDefaultModelOnRedirect ( boolean ignoreDefaultModelOnRedirect ) { } public void setTaskExecutor ( AsyncTaskExecutor taskExecutor ) { } public void setAsyncRequestTimeout ( long timeout ) { } public void setContentNegotiationManager ( ContentNegotiationManager contentNegotiationManager ) { } public void setBeanFactory ( BeanFactory beanFactory ) { } protected ConfigurableBeanFactory getBeanFactory ( ) { } public void afterPropertiesSet ( ) { } private List < HandlerMethodArgumentResolver > getDefaultArgumentResolvers ( ) { } private List < HandlerMethodArgumentResolver > getDefaultInitBinderArgumentResolvers ( ) { } private List < HandlerMethodReturnValueHandler > getDefaultReturnValueHandlers ( ) { } private void initControllerAdviceCache ( ) { } @ Override protected boolean supportsInternal ( HandlerMethod handlerMethod ) { } @ Override protected long getLastModifiedInternal ( HttpServletRequest request , HandlerMethod handlerMethod ) { } @ Override protected final ModelAndView handleInternal ( HttpServletRequest request , HttpServletResponse response , HandlerMethod handlerMethod ) throws Exception { } private SessionAttributesHandler getSessionAttributesHandler ( HandlerMethod handlerMethod ) { } private ModelAndView invokeHandleMethod ( HttpServletRequest request , HttpServletResponse response , HandlerMethod handlerMethod ) throws Exception { } private ServletInvocableHandlerMethod createRequestMappingMethod ( HandlerMethod handlerMethod , WebDataBinderFactory binderFactory ) { ServletInvocableHandlerMethod requestMethod ; <START_BUG> requestMethod = new ServletInvocableHandlerMethod ( handlerMethod . getBean ( ) , handlerMethod . getMethod ( ) ) ; <END_BUG> requestMethod . setHandlerMethodArgumentResolvers ( this . argumentResolvers ) ; requestMethod . setHandlerMethodReturnValueHandlers ( this . returnValueHandlers ) ; requestMethod . setDataBinderFactory ( binderFactory ) ; requestMethod . setParameterNameDiscoverer ( this . parameterNameDiscoverer ) ; return requestMethod ; } private ModelFactory getModelFactory ( HandlerMethod handlerMethod , WebDataBinderFactory binderFactory ) { } private InvocableHandlerMethod createModelAttributeMethod ( WebDataBinderFactory factory , Object bean , Method method ) { } private WebDataBinderFactory getDataBinderFactory ( HandlerMethod handlerMethod ) throws Exception { } private InvocableHandlerMethod createInitBinderMethod ( Object bean , Method method ) { } protected ServletRequestDataBinderFactory createDataBinderFactory ( List < InvocableHandlerMethod > binderMethods ) throws Exception { } private ModelAndView getModelAndView ( ModelAndViewContainer mavContainer , ModelFactory modelFactory , NativeWebRequest webRequest ) throws Exception { } public static final MethodFilter INIT_BINDER_METHODS = new MethodFilter ( ) { public boolean matches ( Method method ) { } } ; public static final MethodFilter MODEL_ATTRIBUTE_METHODS = new MethodFilter ( ) { public boolean matches ( Method method ) { } } ; }

Fix:
requestMethod = new ServletInvocableHandlerMethod ( handlerMethod ) ;