2016-10-23 2 views
0

JPA를 springframework와 통합하려고하는데 오류가 발생했습니다. 이 문제를 해결하는 데 도움을 줄 수있는 사람이 있습니까? 나는 정말로 고칠 것이 없다. URI는 네임 스페이스 선언에 사용되는 것을cvc-complex-type.2.4.c : 일치하는 와일드 카드가 엄격하지만 'context : component-scan'요소에 대한 선언을 찾을 수 없습니다.

<?xml version="1.0" encoding="UTF-8"?> 
<beans xmlns="http://www.springframework.org/schema/beans" 
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
    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://www.springframework.org/schema/beans/spring-beans-4.0.xsd 
    http://www.springframework.org/schema/tx/ http://www.springframework.org/schema/tx/spring-tx-4.0.xsd 
    http://www.springframework.org/schema/mvc http://www.springframework.org/schema/mvc/spring-mvc-4.0.xsd 
    http://www.springframework.org/schema/context/ http://www.springframework.org/schema/context/spring-context-4.0.xsd" > 

    <!-- It register the beans in context and scan the annotations inside beans and activate them --> 
    <context:component-scan base-package="com.mycircle.dao"></context:component-scan> 

    <!-- This allow for dispatching requests to Controllers --> 
    <mvc:annotation-driven /> 

답변

0

참고 URI는 (마지막에 슬래시)의 schemaLocation에 사용 다릅니다

xmlns:context="http://www.springframework.org/schema/context" 

xsi:schemaLocation="http://www.springframework.org/schema/context/ http://www.springframework.org/schema/context/spring-context-4.0.xsd" 

모두의 URI가 동일해야합니다.

희망이 있습니다.

관련 문제