hibernate 的 org.dom4j.DocumentException: Connection timed out 问题

hibbernate的异常的一种情况

一开始以为是数据库连接问题。。。。错了

Communication failure during handshake. Is there a server running on localhost:3306?这个才是数据库连接问题

---特别要注意版本对应,这种问就出现在下面了

问题定位:

org.dom4j.DocumentException: Connection timed out

Connection timed out: connect Nested exception: Connection timed out: connect

出现这个异常的原因之一是读取配置文件超时。

通常是在读取hibernate配置文件验证dtd时版本不对造成的。所以在生成hibernate配置文件的时候要注意配置文件的dtd版本。根据相应的hibernate.jar版本,生成对应的hbm.cfg.xml

如果出现以上异常 可以试下

<!DOCTYPE hibernate-mapping SYSTEM "http://hibernate.sourceforge.net/hibernate-mapping-2.0.dtd" >

转换试下

<!DOCTYPE hibernate-mapping SYSTEM "http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd" >

又或者是反过来!

hibernate 的 org.dom4j.DocumentException: Connection timed out 问题,布布扣,bubuko.com

时间: 2024-08-11 00:09:50

hibernate 的 org.dom4j.DocumentException: Connection timed out 问题的相关文章

ssh启动报错:org.dom4j.DocumentException: Connection timed out: connect Nested exception: Connection timed out: connect

ssh项目启动报错: org.dom4j.DocumentException: Connection timed out: connect Nested exception: Connection timed out: connect 一开始以为是数据库连接的事,后来发现是hibernate在实体对象映射数据库表的时候出的错 解决: 查看hibernate.jar包里的hibernate-mapping-3.0.dtd里的 <!DOCTYPE hibernate-mapping PUBLIC &qu

hibernate3.0 org.dom4j.DocumentException: Connection timed out: connect Nested exception:

hibernate3.0 org.dom4j.DocumentException: Connection timed out: connect Nested exception: 所报异常: 严重: Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListenerorg.springframework.bea

Connection timed out: connect Nested exception

使用dom4j解析自定义的.xml文件. 大致内容如下: Xml代码 <?xml version="1.0" encoding="UTF-8"?><!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"><plist version="1.0&

Caused by: java.lang.ClassNotFoundException: org.dom4j.DocumentException

1.错误描述 信息: Initializing c3p0-0.9.2.1 [built 20-March-2013 10:47:27 +0000; debug? true; trace: 10] 2014-7-12 19:18:48 org.springframework.web.context.ContextLoader initWebApplicationContext 严重: Context initialization failed org.springframework.beans.f

TNS-12535: TNS:operation timed out (WARNING: inbound connection timed out (ORA-3136))

问题原因: Fatal NI connect error 12170.  VERSION INFORMATION:        TNS for Linux: Version 11.2.0.3.0 - Production        Oracle Bequeath NT Protocol Adapter for Linux: Version 11.2.0.3.0 - Production        TCP/IP NT Protocol Adapter for Linux: Version

org.dom4j.DocumentException: null Nested exception: null

1.错误描述 org.dom4j.DocumentException: null Nested exception: null at org.dom4j.io.SAXReader.read(SAXReader.java:484) at org.dom4j.io.SAXReader.read(SAXReader.java:343) at com.you.dom.utils.Reader.main(Reader.java:50) Nested exception: java.net.Malforme

vuser_end.c(3): Error -27796: Failed to connect to server &quot;10.204.105.204:9192&quot;: [10060] Connection timed out

分析 因为负载生成器的性能太好,发数据包特别快,服务器也响应特别快,从而导致负载生成器的机器的端口在没有timeout之前就全部占满了.在全部占满后,就会出现上面的错误.执行netstat–na命令,可以看到打开了很多端口.所以就调整TCP的time out.即在最后一个端口还没有用到时,前面已经有端口在释放了. 成功的解决方法: 在负载生成器的注册表HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip\Parameters里,有如

压测 502 日志报错 upstream timed out (110: Connection timed out)

环境介绍 服务器:centos6.5服务:nginx proxy 问题描述: 压测 开发同事 的开发环境项目没事,但是 线上机器 命中%50 ,大量502 php的某些页面打不开,页面提示gateway timeout,然后查找日志提示如下 2015/09/19 14:00:30 [error] 1811#0: *319 upstream timed out (110: Connection timed out) while reading response header from upstre

java解析XML saxReader.read(xml) 错误:org.dom4j.DocumentException: no protocol

完整错误信息: org.dom4j.DocumentException: no protocol: <?xml version="1.0" encoding="utf-8" ?><smil><subtitle visible="1" fontfamily="宋体" size="36" color="#FFFFFF" bgcolor=""