博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
【解决】Caused by: org.apache.tiles.definition.DefinitionsFactoryException: I/O
阅读量:6419 次
发布时间:2019-06-23

本文共 3651 字,大约阅读时间需要 12 分钟。

hot3.png

使用springmvc tiles模板框架的时候出现如下错误

Caused by: org.apache.tiles.definition.DefinitionsFactoryException: I/O Error reading definitions.     at org.apache.tiles.definition.digester.DigesterDefinitionsReader.read(DigesterDefinitionsReader.java:273)     at org.apache.tiles.definition.UrlDefinitionsFactory.readDefinitions(UrlDefinitionsFactory.java:286)     at org.apache.tiles.definition.UrlDefinitionsFactory.init(UrlDefinitionsFactory.java:130)     at org.apache.tiles.impl.BasicTilesContainer.initializeDefinitionsFactory(BasicTilesContainer.java:406)     at org.apache.tiles.impl.BasicTilesContainer.init(BasicTilesContainer.java:130)     at org.apache.tiles.factory.TilesContainerFactory.initializeContainer(TilesContainerFactory.java:232)     at org.apache.tiles.factory.TilesContainerFactory.createTilesContainer(TilesContainerFactory.java:198)     at org.apache.tiles.factory.TilesContainerFactory.createContainer(TilesContainerFactory.java:163)     at org.apache.tiles.web.startup.TilesListener.createContainer(TilesListener.java:90)     at org.apache.struts2.tiles.StrutsTilesListener.createContainer(StrutsTilesListener.java:68)     at org.apache.tiles.web.startup.TilesListener.contextInitialized(TilesListener.java:57)     ... 15 more Caused by: java.net.SocketException: Connection reset     at java.net.SocketInputStream.read(Unknown Source)     at java.io.BufferedInputStream.fill(Unknown Source)     at java.io.BufferedInputStream.read1(Unknown Source)     at java.io.BufferedInputStream.read(Unknown Source)     at sun.net.www.http.HttpClient.parseHTTPHeader(Unknown Source)     at sun.net.www.http.HttpClient.parseHTTP(Unknown Source)     at sun.net.www.http.HttpClient.parseHTTP(Unknown Source)     at sun.net.www.protocol.http.HttpURLConnection.getInputStream(Unknown Source)     at org.apache.commons.digester.Digester.createInputSourceFromURL(Digester.java:2072)     at org.apache.commons.digester.Digester.resolveEntity(Digester.java:1725)     at com.sun.org.apache.xerces.internal.util.EntityResolverWrapper.resolveEntity(Unknown Source)     at com.sun.org.apache.xerces.internal.impl.XMLEntityManager.resolveEntityAsPerStax(Unknown Source)     at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl$DTDDriver.dispatch(Unknown Source)     at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl$DTDDriver.next(Unknown Source)     at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl$PrologDriver.next(Unknown Source)     at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(Unknown Source)     at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(Unknown Source)     at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)     at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source)     at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source)     at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(Unknown Source)     at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(Unknown Source)     at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Source)     at org.apache.commons.digester.Digester.parse(Digester.java:1887)     at org.apache.tiles.definition.digester.DigesterDefinitionsReader.read(DigesterDefinitionsReader.java:267)

解决方法修改tilesContext.xml文件

把上面的替换成下面的,原来使用的是tiles 2.1 dtd文件修改成3.0问题解决

第二种方法把.dtd文件下载下来 放到tilesContext.xml同级目录 不需要网上验证语法规则,

下载地址 http://tiles.apache.org/dtds/tiles-config_3_0.dtd,tilesContext.xml头文件内容如下

转载于:https://my.oschina.net/zrz1992/blog/1489146

你可能感兴趣的文章
CentOS 6.5 64 安装 mysql-5.7.19
查看>>
iOS 中json解析数据出现中文乱码的问题
查看>>
常见下载节点
查看>>
Spring boot环境搭建(二)- 代码分离、日志文件配置
查看>>
Java动态代理学习1——静态代理
查看>>
node.js学习笔记之正则表达式
查看>>
使用ACL匹配奇偶网络号及IP地址
查看>>
ibatis快速入门(一)
查看>>
四、基于802.1x+AD+NPS+DHCP动态下发VLAN配置 (第4篇、添加角色DHCP服务器并配置)...
查看>>
linux基础命令学习之ls(1)
查看>>
巧用windows批处理,实现简易邮件群发功能
查看>>
我的友情链接
查看>>
深度学习梯度消失或爆炸问题
查看>>
EF How to use context.Set and context.Entry, which ships with EF4.1 ?
查看>>
python-opencv boundingRect使用注意
查看>>
redis cluster
查看>>
HDU 3435A new Graph Game(网络流之最小费用流)
查看>>
newlisp 注释生成文档
查看>>
MySQL float 与decimal 各中的区别。
查看>>
NASA从太空发射激光,制作地球森林高度地图
查看>>