简体   繁体   English

CNF org.springframework.web.servlet.DispatcherServlet

[英]CNF org.springframework.web.servlet.DispatcherServlet

I have included org.springframework.spring-webmvc-4.3.1.RELEASE and tried with 3.2.4.RELEASE even though i am getting this error. 我已经包含org.springframework.spring-webmvc-4.3.1.RELEASE并尝试使用3.2.4.RELEASE即使我遇到此错误。

POM 聚甲醛

<build>
    <plugins>
        <plugin>
            <artifactId>maven-war-plugin</artifactId>
            <version>2.1.1</version>
            <configuration>
                <failOnMissingWebXml>false</failOnMissingWebXml>
            </configuration>
        </plugin>
    </plugins>
</build>
<dependencies>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-webmvc</artifactId>
<version>4.3.1.RELEASE</version>
</dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-core</artifactId>
        <version>3.2.4.RELEASE</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-context</artifactId>
        <version>3.2.4.RELEASE</version>
    </dependency>
    <dependency>
        <groupId>org.springframework</groupId>
        <artifactId>spring-beans</artifactId>
        <version>3.2.4.RELEASE</version>
    </dependency>
    <dependency>
        <groupId>org.springframework.data</groupId>
        <artifactId>spring-data-jpa</artifactId>
        <version>1.4.1.RELEASE</version>
    </dependency>       <dependency>
        <groupId>org.springframework.security</groupId>
        <artifactId>spring-security-core</artifactId>
        <version>3.1.0.RELEASE</version>
    </dependency>
</dependencies>

error 错误

SEVERE: Servlet /SpringMVCTutorial threw load() exception
java.lang.ClassNotFoundException: org.springframework.web.servlet.DispatcherServlet

Any one help 任何人帮忙

EDIT I have added Maven Dependency in Deployment assembly, I'm getting this error now 编辑我已经在部署程序集中添加了Maven依赖关系,我现在收到此错误

ERROR 错误

SEVERE: StandardWrapper.Throwable
org.springframework.beans.factory.parsing.BeanDefinitionParsingException: Configuration problem: Unable to locate Spring NamespaceHandler for XML schema namespace [http://maven.apache.org/POM/4.0.0]
Offending resource: ServletContext resource [/WEB-INF/SpringMVC-servlet.xml]

Project Structure 项目结构

If your IDE is eclipse, Try the following. 如果您的IDE偏食,请尝试以下操作。 Source 资源

You need to add the "Maven Dependency" in the Deployment Assembly 您需要在部署程序集中添加“ Maven依赖关系”

1. right click on your project and choose properties. 1.右键单击您的项目,然后选择属性。 2. click on Deployment Assembly. 2.单击部署程序集。 3. click add 4. click on "Java Build Path Entries" 5. select Maven Dependencies" 6. click Finish. 7. Rebuild and deploy again 3.单击添加 4.单击“ Java构建路径条目” 5.选择“ Maven依赖关系” 6.单击“完成 。7. 重新构建并再次部署

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 错误[org.springframework.web.servlet.DispatcherServlet] - ERROR [org.springframework.web.servlet.DispatcherServlet] 找不到org.springframework.web.servlet.DispatcherServlet - org.springframework.web.servlet.DispatcherServlet Not Found org.springframework.web.servlet.DispatcherServlet noHandlerFound - org.springframework.web.servlet.DispatcherServlet noHandlerFound 实例化servlet类org.springframework.web.servlet.DispatcherServlet时出错 - Error instantiating servlet class org.springframework.web.servlet.Dispatcherservlet org.springframework.web.servlet.DispatcherServlet noHandlerFound:Spring MVC - org.springframework.web.servlet.DispatcherServlet noHandlerFound : Spring MVC java.lang.classnotfoundexception org.springframework.web.servlet.dispatcherservlet - java.lang.classnotfoundexception org.springframework.web.servlet.dispatcherservlet org.springframework.web.servlet.DispatcherServlet class 未找到 - org.springframework.web.servlet.DispatcherServlet class not found org.springframework.web.servlet.DispatcherServlet noHandlerFound用于基本的Spring示例 - org.springframework.web.servlet.DispatcherServlet noHandlerFound for basic spring example org.springframework.web.servlet.DispatcherServlet noHandlerFound 404错误响应 - org.springframework.web.servlet.DispatcherServlet noHandlerFound 404 error response 无法加载org.springframework.web.servlet.DispatcherServlet - Unable to load org.springframework.web.servlet.DispatcherServlet
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM