与元素类型 "beans" 相关联的属性 "xsi:schemaLocation" 的前缀 "xsi" 未绑定。

解决办法:(绿色字体)

<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:mvc="http://www.springframework.org/schema/mvc"
xsi:schemaLocation="
http://www.springframework.org/schema/beans
http://localhost:8081/nexus/content/groups/public/spring/schema/beans/spring-beans-4.3.xsd
http://www.springframework.org/schema/mvc
http://localhost:8081/nexus/content/groups/public/spring/schema/mvc/spring-mvc-4.3.xsd">

其中

http://localhost:8081/nexus/content/groups/public/spring/schema/mvc/spring-mvc-4.3.xsd 为 本地 maven 目录,而且 必须 为 /schema/mvc/***.xsd 结尾。。否则会报错。!!

别漏写 绿色部分,否则也会报错 。。。。。下面附上 spring 和 springMvc 代码

spring
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:aop="http://www.springframework.org/schema/aop" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:p="http://localhost:8081/nexus/content/groups/public/schema/spring/p"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:tx="http://www.springframework.org/schema/tx"
xsi:schemaLocation="
http://www.springframework.org/schema/beans
http://localhost:8081/nexus/content/groups/public/spring/schema/beans/spring-beans-4.3.xsd
http://www.springframework.org/schema/context
http://localhost:8081/nexus/content/groups/public/spring/schema/context/spring-context-4.3.xsd
http://www.springframework.org/schema/tx
http://localhost:8081/nexus/content/groups/public/spring/schema/tx/spring-tx-4.3.xsd
http://www.springframework.org/schema/aop
http://localhost:8081/nexus/content/groups/public/spring/schema/aop/spring-aop-4.3.xsd">

springMvc:

<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:aop="http://www.springframework.org/schema/aop" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:p="http://localhost:8081/nexus/content/groups/public/schema/spring/p"
xmlns:context="http://www.springframework.org/schema/context" xmlns:tx="http://www.springframework.org/schema/tx"
xmlns:mvc="http://www.springframework.org/schema/mvc"
xsi:schemaLocation="
http://www.springframework.org/schema/beans
http://localhost:8081/nexus/content/groups/public/spring/schema/beans/spring-beans-4.3.xsd
http://www.springframework.org/schema/context
http://localhost:8081/nexus/content/groups/public/spring/schema/context/spring-context-4.3.xsd
http://www.springframework.org/schema/tx
http://localhost:8081/nexus/content/groups/public/spring/schema/tx/spring-tx-4.3.xsd
http://www.springframework.org/schema/aop
http://localhost:8081/nexus/content/groups/public/spring/schema/aop/spring-aop-4.3.xsd
http://www.springframework.org/schema/mvc
http://localhost:8081/nexus/content/groups/public/spring/schema/mvc/spring-mvc-4.3.xsd">
												

spring自定义 xsd 位置的更多相关文章

  1. spring自定义标签之 规范定义XSD

    引言: spring的配置文件中,一切的标签都是spring定义好的.<bean/>等等,有了定义的规范,才能让用户填写的正常可用.想写自定义标签,但首先需要了解XML Schema De ...

  2. Spring 自定义标签配置

    前景:经常使用一些依赖于Spring的组件时,发现可以通过自定义配置Spring的标签来实现插件的注入,例如数据库源的配置,Mybatis的配置等.那么这些Spring标签是如何自定义配置的?学习Sp ...

  3. spring自定义schema学习

    [转载请注明作者和原文链接,欢迎讨论,相互学习.] 一.前言 1. 最近在学习dubbo,里边很多如provider.consumer.registry的配置都是通过spring自定义Schema来实 ...

  4. spring 自定义标签的实现

    在我们进行Spring 框架开发中,估计用到最多的就是bean 标签吧,其实在Spring中像<mvc/><context/>这类标签以及在dubbo配置的标签都是属于自定义的 ...

  5. spring基础---->spring自定义标签(一)

    Spring具有一个基于架构的扩展机制,可以使用xml文件定义和配置bean.本博客将介绍如何编写自定义XML bean的解析器,并用实例来加以说明.其实我一直相信 等你出现的时候我就知道是你. Sp ...

  6. spring自定义标签之 自我实现

     引言: 最近心情比较难以平静,周末的两天就跑出去散心了,西湖边上走走,看日落,还是不错的.回来博客上发现,在自定义标签上,最后一步实现忘记加上了.其实,人生的路程中,我们总是实现着自我的价值,让自己 ...

  7. Spring自定义类扫描器 ClassPathScanningCandidateComponentProvider

    项目中有个需求 读取xml文件,然后 对xml文件进行解析,比如如果是 Gender=0/1的话,分别代表男女. 所以需要在构造函数之后,初始化bean之前进行过滤解析 xml文件: <inte ...

  8. spring自定义类中@AutoWired标识的元素注入为null

    最近在做项目的时候,发现程序运行的时候有一个nullpointer exception,一脸懵逼因为感觉程序没什么逻辑.后来发现是因为new出来的component不会自动注入它的元素. 现象:@Co ...

  9. spring基础---->spring自定义初始化(二)

    这里新增了对ref属性的支持,并且过滤了已经解析的元素.人生有两个词很棒,一言不合和不提也罢. spring自定义对ref属性支持 项目的结构如下:新增一个ThirdBean类,修改了ParseXml ...

随机推荐

  1. leetcode479

    public class Solution { public int LargestPalindrome(int n) { ) ; , n) - ; ; v > max / ; v--) { S ...

  2. 如何实现1080P延迟低于500ms的实时超清直播传输技术<转>

    转载地址:http://www.yunweipai.com/archives/9037.html 最近由于公司业务关系,需要一个在公网上能实时互动超清视频的架构和技术方案.众所周知,视频直播用 CDN ...

  3. Stun方式的P2P实现原理(转)

    转帖地址:http://www.cppblog.com/peakflys/archive/2013/01/25/197562.html   二.STUN方式的P2P实现 STUN是RFC3489规定的 ...

  4. hibernate学习笔记(5)在数据库中存取图片

    如何从数据库读取存入的图片,即Blob(二进制)数据. 先从数据库读取对象. 再从获取的对象中得到blob对象. 通过blob对象的getBinaryStream()方法获取input输出流. 之后通 ...

  5. sort排序应用

      private static int SortTestObj2Compare(TestSortClass obj1, TestSortClass obj2)        {            ...

  6. js对象简单、深度克隆(复制)

    javascript的一切实例都是对象,只是对象之间稍有不同,分为原始类型和合成类型.原始类型对象指的是字符串(String).数值(Number).布尔值(Boolean),合成类型对象指的是数组( ...

  7. [codeforces126B]Password

    解题关键:KMP算法中NEXT数组的理解. #include<bits/stdc++.h> #define maxn 1000006 using namespace std; typede ...

  8. winform 打印

    pageSetupDialog 打印设置,和对话框控件差不多的套路,把控件拖到窗口中后,会在下方显示, 然后在制作的菜单中找到打印设置,双击进入点击事件写代码 按照之前的套路, DialogResul ...

  9. 100741A Queries

    传送门 题目 Mathematicians are interesting (sometimes, I would say, even crazy) people. For example, my f ...

  10. MySQL中的时间问题

    MySQL 获得当前日期时间 函数 获得当前日期+时间(date + time)函数:now() mysql> select now(); +---------------------+ | n ...