[英]Spring Webflow - error on spring-context.xml file
I have a project using Spring Webflow and I am getting an error on spring-context.xml file. 我有一个使用Spring Webflow的项目,并且在spring-context.xml文件上遇到错误。
Error: 错误:
cvc-complex-type.2.4.c: The matching wildcard is strict, but no declaration can be found for element 'webflow:flow-executor'. cvc-complex-type.2.4.c:匹配的通配符是严格的,但是找不到元素'webflow:flow-executor'的声明。 spring-context.xml /GestaoAcademicaWeb/WebContent/WEB-INF line 76 XML
spring-context.xml / GestaoAcademicaWeb / WebContent / WEB-INF第76行XML
cvc-complex-type.2.4.c: The matching wildcard is strict, but no declaration can be found for element 'webflow:flow-registry'. cvc-complex-type.2.4.c:匹配的通配符很严格,但是找不到元素'webflow:flow-registry'的声明。 spring-context.xml /GestaoAcademicaWeb/WebContent/WEB-INF line 78 XML
spring-context.xml / GestaoAcademicaWeb / WebContent / WEB-INF第78行XML
My attempts to fix the issue on lines 76 and 78 caused other errors to happen. 我试图在第76和78行上解决此问题,导致发生其他错误。 Any guess of what is wrong on this file?
您对此文件有什么疑问吗?
This is the spring-context.xml file. 这是spring-context.xml文件。
<?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:aop="http://www.springframework.org/schema/aop"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:jee="http://www.springframework.org/schema/jee"
xmlns:lang="http://www.springframework.org/schema/lang"
xmlns:p="http://www.springframework.org/schema/p"
xmlns:tx="http://www.springframework.org/schema/tx"
xmlns:util="http://www.springframework.org/schema/util"
xmlns:mvc="http://www.springframework.org/schema/mvc"
xmlns:webflow="http://www.springframework.org/schema/webflow-config"
xsi:schemaLocation="http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans.xsd
http://www.springframework.org/schema/aop
http://www.springframework.org/schema/aop/spring-aop.xsd
http://www.springframework.org/schema/context
http://www.springframework.org/schema/context/spring-context.xsd
http://www.springframework.org/schema/jee
http://www.springframework.org/schema/jee/spring-jee.xsd
http://www.springframework.org/schema/lang
http://www.springframework.org/schema/lang/spring-lang.xsd
http://www.springframework.org/schema/tx
http://www.springframework.org/schema/tx/spring-tx.xsd
http://www.springframework.org/schema/util
http://www.springframework.org/schema/util/spring-util.xsd
http://www.springframework.org/schema/mvc
http://www.springframework.org/schema/mvc/spring-mvc-3.0.xsd
http://www.springframework.org/schema/webflow-config
http://www.springframework.org/schema/webflow-config/spring-webflow-config-2.0.xsd">
<context:annotation-config />
<context:component-scan
base-package="br.com.devmedia.gestaoacademicaweb" />
<bean id="jspViewResolver"
class="org.springframework.web.servlet.view.InternalResourceViewResolver">
<property name="viewClass"
value="org.springframework.web.servlet.view.JstlView" />
<property name="prefix" value="/WEB-INF/views/" />
<property name="suffix" value=".jsp" />
</bean>
<bean id="propertyConfigurer"
class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer"
p:location="/WEB-INF/jdbc.properties" />
<bean id="dataSource"
class="org.apache.commons.dbcp.BasicDataSource" destroy-method="close"
p:driverClassName="${jdbc.driverClassName}"
p:url="${jdbc.databaseurl}" p:username="${jdbc.username}"
p:password="${jdbc.password}" />
<bean id="sessionFactory"
class="org.springframework.orm.hibernate4.LocalSessionFactoryBean">
<property name="dataSource" ref="dataSource" />
<property name="configLocation">
<value>classpath:hibernate.cfg.xml</value>
</property>
<property name="hibernateProperties">
<props>
<prop key="hibernate.dialect">${jdbc.dialect}</prop>
<prop key="hibernate.show_sql">true</prop>
</props>
</property>
</bean>
<tx:annotation-driven />
<bean id="transactionManager"
class="org.springframework.orm.hibernate4.HibernateTransactionManager">
<property name="sessionFactory" ref="sessionFactory" />
</bean>
<webflow:flow-executor id="flowExecutor" />
<webflow:flow-registry id="flowRegistry">
<webflow:flow-location
path="/WEB-INF/flows/inserirDocente.xml" id="inserirDocente" />
</webflow:flow-registry>
<bean
class="org.springframework.webflow.mvc.servlet.FlowHandlerMapping">
<property name="flowRegistry" ref="flowRegistry" />
<property name="order" value="0" />
</bean>
<bean
class="org.springframework.webflow.mvc.servlet.FlowHandlerAdapter">
<property name="flowExecutor" ref="flowExecutor" />
</bean>
<bean name="docenteController"
class="br.com.devmedia.gestaoacademicaweb.control.DocenteController" />
</beans>
将schemaLocation
URL替换为以下较新的URL:
http://www.springframework.org/schema/webflow-config/spring-webflow-config.xsd
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.