web.xml中<async-supported>报错异常

来源:互联网 发布:网上接软件项目 编辑:程序博客网 时间:2024/06/05 18:18

错误异常:

cvc-complex-type.2.4.a: Invalid content was found starting with element 'async-supported'. One of 

 '{"http://java.sun.com/xml/ns/javaee":init-param}' is expected.


<async-supported>true</async-supported> 


解决方案:

xmlns中再加两行

http://www.springmodules.org/schema/cache/springmodules-cache.xsd  
http://www.springmodules.org/schema/cache/springmodules-ehcache.xsd


如:

<?xml version="1.0" encoding="UTF-8"?><web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaeehttp://www.springmodules.org/schema/cache/springmodules-cache.xsd  http://www.springmodules.org/schema/cache/springmodules-ehcache.xsd" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" id="WebApp_ID" version="2.5">

0 0