Error creating bean with name 'mvcContentNegotiationManager'

警告: Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'mvcContentNegotiationManager': Failed to introspect bean class [org.springframework.web.accept.ContentNegotiationManagerFactoryBean] for lookup method metadata: could not find class that it depends on; nested exception is java.lang.NoClassDefFoundError: javax/servlet/ServletContext


缺少servlet-api的依赖包

 <dependency>
            <groupId>tomcat</groupId>
            <artifactId>servlet-api</artifactId>
            <version>5.5.23</version>
        </dependency>



猜你喜欢

转载自blog.csdn.net/asd104/article/details/75579642