org.springframework.web.servlet.resource.ResourceHttpRequestHandler#0': Invocation of init method failed; nested exception is java.lang.IllegalStateExceptionresolvers=[org.springframework.web.servlet.resource.PathResourceResolver@43bd930a]]] does not run in a WebApplicationContext<
我试图集成Security,但是当我按照AbstractSecurityWebApplicationInitializer的指示添加一个扩展的类时,我会得到以下例外:
java.lang.IllegalStateException: No WebApplicationContextfound: no ContextLoaderListener registered?
SEVERE: Exception starting filter cuppytrailfrontendPlatformFilterChain
java.lang.IllegalStateException: Context attribute is not of type WebApplicationContext: Root WebApplicationContext - /cuppytrailfrontend
springSecurityFilterChain</filter-name> </filter-mapping>java.lang.IllegalStateException: No WebApplicationContextfound: no ContextLoaderListener registered?
java.lang.IllegalStateException: No WebApplicationContextfound: no ContextLoaderListener registered?org.springframework.beans.factory.NoSuchBeanDefinitionException: No matching bean of type [xxxxxx] found
| Error Fatal error running tests: No WebApplicationContextfound: no ContextLoaderListener registeredUse --verbose to see entire trace.) at gant.Gant.executeTargets(Gant