Configuration problem: Unable to locate Spring NamespaceHandler for XML schema namespace [http://www

原文连接: http://www.javacreed.com/unable-to-locate-spring-namespacehandler-for-xml-schema-namespace-httpwww-springframework-orgschemamvc/   


Error

The web application fails to start due to the following error

org.springframework.beans.factory.parsing.BeanDefinitionParsingException: Configuration problem: Unable to locate Spring NamespaceHandler for XML schema namespace [http://www.springframework.org/schema/mvc]

Solution

You need to have the JAR file: spring-webmvc-3.1.0.RELEASE.jar (or a newer version if available – check from here) in your web application classpath. If you are using Maven, simply add the following to your dependencies.

<dependency>
  <groupId>org.springframework</groupId>
  <artifactId>spring-webmvc</artifactId>
  <version>3.1.0.RELEASE</version>
</dependency>

Make sure you also have the following dependencies in your classpath, as otherwise the web application may not start due to missing classes:

  • Spring Web JAR file: spring-web-3.1.0.RELEASE.jar
    <dependency>
      <groupId>org.springframework</groupId>
      <artifactId>spring-web</artifactId>
      <version>3.1.0.RELEASE</version>
    </dependency>
    
  • Hibernate Validator JAR file: hibernate-validator-4.3.0.Final.jar
    <dependency>
      <groupId>org.hibernate</groupId>
      <artifactId>hibernate-validator-annotation-processor</artifactId>
      <version>4.3.0.Final</version>
    </dependency>
    
Albert Attard

Albert Attard

Albert Attard is a Java passionate and technical lead at a research group. You can find him onGoogle+. Over the past years Albert worked on various Java projects including traditional server/client applications, modular applications, large data handling applications and concurrent data manipulation applications to name a few. He has a BSc degree from the University of London (Homepage) and an MSc Information Security with the same university. His MSc thesis (Book) received the 2012 SearchSecurity.co.UK award (Website).


  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值