I have an a application which up until yesterday ran fine both locally and on AWS. Suddenly the application has failed to work when calling /oauth/token on the AWS deployed version of the code - whilst locally the application runs fine without error. Both local and AWS based applications had been running AOK up until friday - and no material code changes occurred between friday and the previous deployment (Thursday). I have entirely rebuilt the AWS environment believing it to be an environment issue, however this did not resolve the issue.
The problem: When calling /oauth/token with a (previously) valid formatted POST request I am receiving a 405 Method Not Allowed.
What I have uncovered so far is the following:
Key Jars are Spring Boot 1.2.3.RELEASE, Spring OAuth2 2.0.7.RELEEASE running in Tomcat 8/Java 8 Elasticbeanstalk.
The error I am receiving when calling /oauth/token via JSON:
405
Allow = "HEAD, GET";
"Cache-Control" = "no-cache, no-store, max-age=0, must-revalidate";
Connection = close;
"Content-Type" = "application/json;charset=UTF-8";
Date = "Sun, 03 May 2015 00:13:00 GMT";
Expires = 0;
Pragma = "no-cache";
Server = "Apache-Coyote/1.1";
"Transfer-Encoding" = Identity;
"X-Content-Type-Options" = nosniff;
"X-Frame-Options" = DENY;
"X-XSS-Protection" = "1; mode=block";
{"timestamp":1430611980,"status":405,"error":"Method Not Allowed","exception":"org.springframework.web.HttpRequestMethodNotSupportedException","message":"Request method 'POST' not supported"}
The application startup logs relating to the mapping of the Spring TokenEndpoint to handle the /oauth/* url paths. In particular /oauth/token appears to be mapped to POST correctly:
2015-05-03 00:11:52.718 INFO --- [ost-startStop-1] .s.o.p.e.FrameworkEndpointHandlerMapping : Mapped "{[/oauth/authorize],methods=[],params=[],headers=[],consumes=[],produces=[],custom=[]}" onto public org.springframework.web.servlet.ModelAndView org.springframework.security.oauth2.provider.endpoint.AuthorizationEndpoint.authorize(java.util.Map<java.lang.String, java.lang.Object>,java.util.Map<java.lang.String, java.lang.String>,org.springframework.web.bind.support.SessionStatus,java.security.Principal)
2015-05-03 00:11:52.718 TRACE --- [ost-startStop-1] .s.o.p.e.FrameworkEndpointHandlerMapping : Mapping name=AE#authorize
2015-05-03 00:11:52.718 INFO --- [ost-startStop-1] .s.o.p.e.FrameworkEndpointHandlerMapping : Mapped "{[/oauth/authorize],methods=[POST],params=[user_oauth_approval],headers=[],consumes=[],produces=[],custom=[]}" onto public org.springframework.web.servlet.View org.springframework.security.oauth2.provider.endpoint.AuthorizationEndpoint.approveOrDeny(java.util.Map<java.lang.String, java.lang.String>,java.util.Map<java.lang.String, ?>,org.springframework.web.bind.support.SessionStatus,java.security.Principal)
2015-05-03 00:11:52.718 TRACE --- [ost-startStop-1] .s.o.p.e.FrameworkEndpointHandlerMapping : Mapping name=AE#approveOrDeny
2015-05-03 00:11:52.720 INFO --- [ost-startStop-1] .s.o.p.e.FrameworkEndpointHandlerMapping : Mapped "{[/oauth/token],methods=[GET],params=[],headers=[],consumes=[],produces=[],custom=[]}" onto public org.springframework.http.ResponseEntity<org.springframework.security.oauth2.common.OAuth2AccessToken> org.springframework.security.oauth2.provider.endpoint.TokenEndpoint.getAccessToken(java.security.Principal,java.util.Map<java.lang.String, java.lang.String>) throws org.springframework.web.HttpRequestMethodNotSupportedException
2015-05-03 00:11:52.720 TRACE --- [ost-startStop-1] .s.o.p.e.FrameworkEndpointHandlerMapping : Mapping name=TE#getAccessToken
2015-05-03 00:11:52.720 INFO --- [ost-startStop-1] .s.o.p.e.FrameworkEndpointHandlerMapping : Mapped "{[/oauth/token],methods=[POST],params=[],headers=[],consumes=[],produces=[],custom=[]}" onto public org.springframework.http.ResponseEntity<org.springframework.security.oauth2.common.OAuth2AccessToken> org.springframework.security.oauth2.provider.endpoint.TokenEndpoint.postAccessToken(java.security.Principal,java.util.Map<java.lang.String, java.lang.String>) throws org.springframework.web.HttpRequestMethodNotSupportedException
2015-05-03 00:11:52.720 TRACE --- [ost-startStop-1] .s.o.p.e.FrameworkEndpointHandlerMapping : Mapping name=TE#postAccessToken
2015-05-03 00:11:52.721 INFO --- [ost-startStop-1] .s.o.p.e.FrameworkEndpointHandlerMapping : Mapped "{[/oauth/check_token],methods=[],params=[],headers=[],consumes=[],produces=[],custom=[]}" onto public java.util.Map<java.lang.String, ?> org.springframework.security.oauth2.provider.endpoint.CheckTokenEndpoint.checkToken(java.lang.String)
2015-05-03 00:11:52.721 TRACE --- [ost-startStop-1] .s.o.p.e.FrameworkEndpointHandlerMapping : Mapping name=CTE#checkToken
2015-05-03 00:11:52.721 INFO --- [ost-startStop-1] .s.o.p.e.FrameworkEndpointHandlerMapping : Mapped "{[/oauth/confirm_access],methods=[],params=[],headers=[],consumes=[],produces=[],custom=[]}" onto public org.springframework.web.servlet.ModelAndView org.springframework.security.oauth2.provider.endpoint.WhitelabelApprovalEndpoint.getAccessConfirmation(java.util.Map<java.lang.String, java.lang.Object>,javax.servlet.http.HttpServletRequest) throws java.lang.Exception
2015-05-03 00:11:52.721 TRACE --- [ost-startStop-1] .s.o.p.e.FrameworkEndpointHandlerMapping : Mapping name=WAE#getAccessConfirmation
2015-05-03 00:11:52.722 INFO --- [ost-startStop-1] .s.o.p.e.FrameworkEndpointHandlerMapping : Mapped "{[/oauth/error],methods=[],params=[],headers=[],consumes=[],produces=[],custom=[]}" onto public org.springframework.web.servlet.ModelAndView org.springframework.security.oauth2.provider.endpoint.WhitelabelErrorEndpoint.handleError(javax.servlet.http.HttpServletRequest)
And, lastly, the request being handled (trace enabled) for the /oauth/token URL:
2015-05-03 00:13:00.159 TRACE --- [nio-8080-exec-2] o.s.b.a.trace.WebRequestTraceFilter : Processing request POST /oauth/token
2015-05-03 00:13:00.159 DEBUG --- [nio-8080-exec-2] o.s.s.w.u.matcher.AntPathRequestMatcher : Checking match of request : '/oauth/token'; against '/css/**'
2015-05-03 00:13:00.159 DEBUG --- [nio-8080-exec-2] o.s.s.w.u.matcher.AntPathRequestMatcher : Checking match of request : '/oauth/token'; against '/js/**'
2015-05-03 00:13:00.159 DEBUG --- [nio-8080-exec-2] o.s.s.w.u.matcher.AntPathRequestMatcher : Checking match of request : '/oauth/token'; against '/images/**'
2015-05-03 00:13:00.159 DEBUG --- [nio-8080-exec-2] o.s.s.w.u.matcher.AntPathRequestMatcher : Checking match of request : '/oauth/token'; against '/**/favicon.ico'
2015-05-03 00:13:00.159 DEBUG --- [nio-8080-exec-2] o.s.s.w.u.matcher.AntPathRequestMatcher : Checking match of request : '/oauth/token'; against '/error'
2015-05-03 00:13:00.159 DEBUG --- [nio-8080-exec-2] o.s.s.web.util.matcher.OrRequestMatcher : Trying to match using Ant [pattern='/oauth/token']
2015-05-03 00:13:00.159 DEBUG --- [nio-8080-exec-2] o.s.s.w.u.matcher.AntPathRequestMatcher : Checking match of request : '/oauth/token'; against '/oauth/token'
2015-05-03 00:13:00.159 DEBUG --- [nio-8080-exec-2] o.s.s.web.util.matcher.OrRequestMatcher : matched
2015-05-03 00:13:00.159 DEBUG --- [nio-8080-exec-2] o.s.security.web.FilterChainProxy : /oauth/token at position 1 of 11 in additional filter chain; firing Filter: 'WebAsyncManagerIntegrationFilter'
2015-05-03 00:13:00.159 DEBUG --- [nio-8080-exec-2] o.s.security.web.FilterChainProxy : /oauth/token at position 2 of 11 in additional filter chain; firing Filter: 'SecurityContextPersistenceFilter'
2015-05-03 00:13:00.160 DEBUG --- [nio-8080-exec-2] o.s.security.web.FilterChainProxy : /oauth/token at position 3 of 11 in additional filter chain; firing Filter: 'HeaderWriterFilter'
2015-05-03 00:13:00.160 DEBUG --- [nio-8080-exec-2] o.s.s.w.header.writers.HstsHeaderWriter : Not injecting HSTS header since it did not match the requestMatcher org.springframework.security.web.header.writers.HstsHeaderWriter$SecureRequestMatcher@239f5596
2015-05-03 00:13:00.160 DEBUG --- [nio-8080-exec-2] o.s.security.web.FilterChainProxy : /oauth/token at position 4 of 11 in additional filter chain; firing Filter: 'LogoutFilter'
2015-05-03 00:13:00.160 DEBUG --- [nio-8080-exec-2] o.s.s.w.u.matcher.AntPathRequestMatcher : Checking match of request : '/oauth/token'; against '/logout'
2015-05-03 00:13:00.160 DEBUG --- [nio-8080-exec-2] o.s.security.web.FilterChainProxy : /oauth/token at position 5 of 11 in additional filter chain; firing Filter: 'BasicAuthenticationFilter'
2015-05-03 00:13:00.162 DEBUG --- [nio-8080-exec-2] o.s.s.w.a.http://ift.tt/1cnl2OP : Basic Authentication Authorization header found for user 'wander-ios'
2015-05-03 00:13:00.163 DEBUG --- [nio-8080-exec-2] o.s.s.authentication.ProviderManager : Authentication attempt using org.springframework.security.authentication.dao.DaoAuthenticationProvider
2015-05-03 00:13:00.166 DEBUG --- [nio-8080-exec-2] o.s.b.f.s.DefaultListableBeanFactory : Creating shared instance of singleton bean 'scopedTarget.clientDetailsService'
2015-05-03 00:13:00.166 DEBUG --- [nio-8080-exec-2] o.s.b.f.s.DefaultListableBeanFactory : Creating instance of bean 'scopedTarget.clientDetailsService'
2015-05-03 00:13:00.166 DEBUG --- [nio-8080-exec-2] o.s.b.f.s.DefaultListableBeanFactory : Returning cached instance of singleton bean 'metaDataSourceAdvisor'
2015-05-03 00:13:00.166 DEBUG --- [nio-8080-exec-2] o.s.b.f.s.DefaultListableBeanFactory : Returning cached instance of singleton bean 'org.springframework.security.oauth2.config.annotation.configuration.ClientDetailsServiceConfiguration'
2015-05-03 00:13:00.169 DEBUG --- [nio-8080-exec-2] o.s.b.f.s.DefaultListableBeanFactory : Eagerly caching bean 'scopedTarget.clientDetailsService' to allow for resolving potential circular references
2015-05-03 00:13:00.170 TRACE --- [nio-8080-exec-2] o.s.beans.CachedIntrospectionResults : Getting BeanInfo for class [org.springframework.security.oauth2.provider.client.InMemoryClientDetailsService]
2015-05-03 00:13:00.172 TRACE --- [nio-8080-exec-2] o.s.beans.CachedIntrospectionResults : Caching PropertyDescriptors for class [org.springframework.security.oauth2.provider.client.InMemoryClientDetailsService]
2015-05-03 00:13:00.172 TRACE --- [nio-8080-exec-2] o.s.beans.CachedIntrospectionResults : Found bean property 'class' of type [java.lang.Class]
2015-05-03 00:13:00.172 TRACE --- [nio-8080-exec-2] o.s.beans.CachedIntrospectionResults : Found bean property 'clientDetailsStore' of type [java.util.Map]
2015-05-03 00:13:00.172 DEBUG --- [nio-8080-exec-2] o.s.b.f.s.DefaultListableBeanFactory : Returning cached instance of singleton bean 'metaDataSourceAdvisor'
2015-05-03 00:13:00.173 DEBUG --- [nio-8080-exec-2] o.s.b.f.s.DefaultListableBeanFactory : Returning cached instance of singleton bean 'metaDataSourceAdvisor'
2015-05-03 00:13:00.173 DEBUG --- [nio-8080-exec-2] s.a.ScheduledAnnotationBeanPostProcessor : No @Scheduled annotations found on bean class: class org.springframework.security.oauth2.provider.client.InMemoryClientDetailsService
2015-05-03 00:13:00.173 DEBUG --- [nio-8080-exec-2] o.s.b.f.s.DefaultListableBeanFactory : Finished creating instance of bean 'scopedTarget.clientDetailsService'
2015-05-03 00:13:00.178 DEBUG --- [nio-8080-exec-2] o.s.s.w.a.http://ift.tt/1cnl2OP : Authentication success: org.springframework.security.authentication.UsernamePasswordAuthenticationToken@bb5fd4d6: Principal: org.springframework.security.core.userdetails.User@bb780ced: Username: wander-ios; Password: [PROTECTED]; Enabled: true; AccountNonExpired: true; credentialsNonExpired: true; AccountNonLocked: true; Granted Authorities: USER; Credentials: [PROTECTED]; Authenticated: true; Details: org.springframework.security.web.authentication.WebAuthenticationDetails@ffffc434: RemoteIpAddress: 146.200.167.251; SessionId: null; Granted Authorities: USER
2015-05-03 00:13:00.178 DEBUG --- [nio-8080-exec-2] o.s.security.web.FilterChainProxy : /oauth/token at position 6 of 11 in additional filter chain; firing Filter: 'RequestCacheAwareFilter'
2015-05-03 00:13:00.178 DEBUG --- [nio-8080-exec-2] o.s.security.web.FilterChainProxy : /oauth/token at position 7 of 11 in additional filter chain; firing Filter: 'SecurityContextHolderAwareRequestFilter'
2015-05-03 00:13:00.178 DEBUG --- [nio-8080-exec-2] o.s.security.web.FilterChainProxy : /oauth/token at position 8 of 11 in additional filter chain; firing Filter: 'AnonymousAuthenticationFilter'
2015-05-03 00:13:00.178 DEBUG --- [nio-8080-exec-2] o.s.s.w.a.AnonymousAuthenticationFilter : SecurityContextHolder not populated with anonymous token, as it already contained: 'org.springframework.security.authentication.UsernamePasswordAuthenticationToken@bb5fd4d6: Principal: org.springframework.security.core.userdetails.User@bb780ced: Username: wander-ios; Password: [PROTECTED]; Enabled: true; AccountNonExpired: true; credentialsNonExpired: true; AccountNonLocked: true; Granted Authorities: USER; Credentials: [PROTECTED]; Authenticated: true; Details: org.springframework.security.web.authentication.WebAuthenticationDetails@ffffc434: RemoteIpAddress: 146.200.167.251; SessionId: null; Granted Authorities: USER'
2015-05-03 00:13:00.178 DEBUG --- [nio-8080-exec-2] o.s.security.web.FilterChainProxy : /oauth/token at position 9 of 11 in additional filter chain; firing Filter: 'SessionManagementFilter'
2015-05-03 00:13:00.178 DEBUG --- [nio-8080-exec-2] s.CompositeSessionAuthenticationStrategy : Delegating to org.springframework.security.web.authentication.session.ChangeSessionIdAuthenticationStrategy@66207ac
2015-05-03 00:13:00.178 DEBUG --- [nio-8080-exec-2] o.s.security.web.FilterChainProxy : /oauth/token at position 10 of 11 in additional filter chain; firing Filter: 'ExceptionTranslationFilter'
2015-05-03 00:13:00.178 DEBUG --- [nio-8080-exec-2] o.s.security.web.FilterChainProxy : /oauth/token at position 11 of 11 in additional filter chain; firing Filter: 'FilterSecurityInterceptor'
2015-05-03 00:13:00.178 DEBUG --- [nio-8080-exec-2] o.s.s.w.u.matcher.AntPathRequestMatcher : Checking match of request : '/oauth/token'; against '/oauth/token'
2015-05-03 00:13:00.178 DEBUG --- [nio-8080-exec-2] o.s.s.w.a.i.FilterSecurityInterceptor : Secure object: FilterInvocation: URL: /oauth/token; Attributes: [fullyAuthenticated]
2015-05-03 00:13:00.178 DEBUG --- [nio-8080-exec-2] o.s.s.w.a.i.FilterSecurityInterceptor : Previously Authenticated: org.springframework.security.authentication.UsernamePasswordAuthenticationToken@bb5fd4d6: Principal: org.springframework.security.core.userdetails.User@bb780ced: Username: wander-ios; Password: [PROTECTED]; Enabled: true; AccountNonExpired: true; credentialsNonExpired: true; AccountNonLocked: true; Granted Authorities: USER; Credentials: [PROTECTED]; Authenticated: true; Details: org.springframework.security.web.authentication.WebAuthenticationDetails@ffffc434: RemoteIpAddress: 146.200.167.251; SessionId: null; Granted Authorities: USER
2015-05-03 00:13:00.179 DEBUG --- [nio-8080-exec-2] o.s.s.access.vote.AffirmativeBased : Voter: org.springframework.security.web.access.expression.WebExpressionVoter@110d157f, returned: 1
2015-05-03 00:13:00.179 DEBUG --- [nio-8080-exec-2] o.s.s.w.a.i.FilterSecurityInterceptor : Authorization successful
2015-05-03 00:13:00.179 DEBUG --- [nio-8080-exec-2] o.s.s.w.a.i.FilterSecurityInterceptor : RunAsManager did not change Authentication object
2015-05-03 00:13:00.179 DEBUG --- [nio-8080-exec-2] o.s.security.web.FilterChainProxy : /oauth/token reached end of additional filter chain; proceeding with original chain
2015-05-03 00:13:00.180 DEBUG --- [nio-8080-exec-2] o.s.b.f.s.DefaultListableBeanFactory : Returning cached instance of singleton bean 'managementServerProperties'
2015-05-03 00:13:00.182 TRACE --- [nio-8080-exec-2] o.s.web.servlet.DispatcherServlet : Bound request context to thread: SecurityContextHolderAwareRequestWrapper[ FirewalledRequest[ org.apache.catalina.connector.RequestFacade@62ea2082]]
2015-05-03 00:13:00.182 DEBUG --- [nio-8080-exec-2] o.s.web.servlet.DispatcherServlet : DispatcherServlet with name 'dispatcherServlet' processing POST request for [/oauth/token]
2015-05-03 00:13:00.183 TRACE --- [nio-8080-exec-2] o.s.web.servlet.DispatcherServlet : Testing handler map [org.springframework.web.servlet.handler.SimpleUrlHandlerMapping@3d4e9921] in DispatcherServlet with name 'dispatcherServlet'
2015-05-03 00:13:00.184 TRACE --- [nio-8080-exec-2] o.s.w.s.handler.SimpleUrlHandlerMapping : No handler mapping found for [/oauth/token]
2015-05-03 00:13:00.184 TRACE --- [nio-8080-exec-2] o.s.web.servlet.DispatcherServlet : Testing handler map [org.springframework.boot.actuate.endpoint.mvc.EndpointHandlerMapping@282c7c01] in DispatcherServlet with name 'dispatcherServlet'
2015-05-03 00:13:00.184 DEBUG --- [nio-8080-exec-2] o.s.b.a.e.mvc.EndpointHandlerMapping : Looking up handler method for path /oauth/token
2015-05-03 00:13:00.185 DEBUG --- [nio-8080-exec-2] o.s.b.a.e.mvc.EndpointHandlerMapping : Did not find handler method for [/oauth/token]
2015-05-03 00:13:00.185 TRACE --- [nio-8080-exec-2] o.s.web.servlet.DispatcherServlet : Testing handler map [org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMapping@61e27fb4] in DispatcherServlet with name 'dispatcherServlet'
2015-05-03 00:13:00.185 DEBUG --- [nio-8080-exec-2] s.w.s.m.m.a.RequestMappingHandlerMapping : Looking up handler method for path /oauth/token
2015-05-03 00:13:00.190 DEBUG --- [nio-8080-exec-2] s.w.s.m.m.a.RequestMappingHandlerMapping : Did not find handler method for [/oauth/token]
2015-05-03 00:13:00.190 TRACE --- [nio-8080-exec-2] o.s.web.servlet.DispatcherServlet : Testing handler map [org.springframework.integration.http.inbound.IntegrationRequestMappingHandlerMapping@6dfb9823] in DispatcherServlet with name 'dispatcherServlet'
2015-05-03 00:13:00.190 DEBUG --- [nio-8080-exec-2] .IntegrationRequestMappingHandlerMapping : Looking up handler method for path /oauth/token
2015-05-03 00:13:00.190 DEBUG --- [nio-8080-exec-2] .IntegrationRequestMappingHandlerMapping : Did not find handler method for [/oauth/token]
2015-05-03 00:13:00.190 TRACE --- [nio-8080-exec-2] o.s.web.servlet.DispatcherServlet : Testing handler map [org.springframework.web.servlet.handler.BeanNameUrlHandlerMapping@75e4e122] in DispatcherServlet with name 'dispatcherServlet'
2015-05-03 00:13:00.190 TRACE --- [nio-8080-exec-2] o.s.w.s.h.BeanNameUrlHandlerMapping : No handler mapping found for [/oauth/token]
2015-05-03 00:13:00.190 TRACE --- [nio-8080-exec-2] o.s.web.servlet.DispatcherServlet : Testing handler map [org.springframework.web.servlet.handler.SimpleUrlHandlerMapping@78db6873] in DispatcherServlet with name 'dispatcherServlet'
2015-05-03 00:13:00.190 DEBUG --- [nio-8080-exec-2] o.s.w.s.handler.SimpleUrlHandlerMapping : Matching patterns for request [/oauth/token] are [/**]
2015-05-03 00:13:00.191 DEBUG --- [nio-8080-exec-2] o.s.w.s.handler.SimpleUrlHandlerMapping : URI Template variables for request [/oauth/token] are {}
2015-05-03 00:13:00.196 DEBUG --- [nio-8080-exec-2] o.s.w.s.handler.SimpleUrlHandlerMapping : Mapping [/oauth/token] to HandlerExecutionChain with handler [ResourceHttpRequestHandler [locations=[ServletContext resource [/], class path resource [META-INF/resources/], class path resource [resources/], class path resource [static/], class path resource [public/]], resolvers=[org.springframework.web.servlet.resource.PathResourceResolver@2e34820]]] and 1 interceptor
2015-05-03 00:13:00.197 TRACE --- [nio-8080-exec-2] o.s.web.servlet.DispatcherServlet : Testing handler adapter [org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter@604e4ed1]
2015-05-03 00:13:00.197 TRACE --- [nio-8080-exec-2] o.s.web.servlet.DispatcherServlet : Testing handler adapter [org.springframework.web.servlet.mvc.HttpRequestHandlerAdapter@331deeee]
2015-05-03 00:13:00.199 DEBUG --- [nio-8080-exec-2] .w.s.m.a.ResponseStatusExceptionResolver : Resolving exception from handler [ResourceHttpRequestHandler [locations=[ServletContext resource [/], class path resource [META-INF/resources/], class path resource [resources/], class path resource [static/], class path resource [public/]], resolvers=[org.springframework.web.servlet.resource.PathResourceResolver@2e34820]]]: org.springframework.web.HttpRequestMethodNotSupportedException: Request method 'POST' not supported
2015-05-03 00:13:00.199 DEBUG --- [nio-8080-exec-2] .w.s.m.s.DefaultHandlerExceptionResolver : Resolving exception from handler [ResourceHttpRequestHandler [locations=[ServletContext resource [/], class path resource [META-INF/resources/], class path resource [resources/], class path resource [static/], class path resource [public/]], resolvers=[org.springframework.web.servlet.resource.PathResourceResolver@2e34820]]]: org.springframework.web.HttpRequestMethodNotSupportedException: Request method 'POST' not supported
2015-05-03 00:13:00.200 WARN --- [nio-8080-exec-2] o.s.web.servlet.PageNotFound : Request method 'POST' not supported
2015-05-03 00:13:00.200 DEBUG --- [nio-8080-exec-2] o.s.web.servlet.DispatcherServlet : Null ModelAndView returned to DispatcherServlet with name 'dispatcherServlet': assuming HandlerAdapter completed request handling
2015-05-03 00:13:00.201 TRACE --- [nio-8080-exec-2] o.s.web.servlet.DispatcherServlet : Cleared thread-bound request context: SecurityContextHolderAwareRequestWrapper[ FirewalledRequest[ org.apache.catalina.connector.RequestFacade@62ea2082]]
2015-05-03 00:13:00.201 DEBUG --- [nio-8080-exec-2] o.s.web.servlet.DispatcherServlet : Successfully completed request
2015-05-03 00:13:00.201 TRACE --- [nio-8080-exec-2] ationConfigEmbeddedWebApplicationContext : Publishing event in org.springframework.boot.context.embedded.AnnotationConfigEmbeddedWebApplicationContext@58945a18: ServletRequestHandledEvent: url=[/oauth/token]; client=[146.200.167.251]; method=[POST]; servlet=[dispatcherServlet]; session=[null]; user=[wander-ios]; time=[20ms]; status=[OK]
2015-05-03 00:13:00.201 DEBUG --- [nio-8080-exec-2] o.s.b.f.s.DefaultListableBeanFactory : Returning cached instance of singleton bean 'delegatingApplicationListener'
2015-05-03 00:13:00.201 DEBUG --- [nio-8080-exec-2] o.s.b.f.s.DefaultListableBeanFactory : Returning cached instance of singleton bean 'org.springframework.integration.internalMessagingAnnotationPostProcessor'
2015-05-03 00:13:00.202 DEBUG --- [nio-8080-exec-2] o.s.s.w.a.ExceptionTranslationFilter : Chain processed normally
2015-05-03 00:13:00.202 DEBUG --- [nio-8080-exec-2] s.s.w.c.SecurityContextPersistenceFilter : SecurityContextHolder now cleared, as request processing completed
I can't for the life of me figure out why the request is being handled by the resource servlet rather than the TokenEndpoint. Any clues appreciated!
Aucun commentaire:
Enregistrer un commentaire