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

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

Caused by: org.hibernate.InvalidMappingException: Unable to read XML

第一种情况:

解决:

  查看hibernate.jar包里的hibernate-mapping-3.0.dtd里的

    <!DOCTYPE hibernate-mapping PUBLIC 
      "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
      "http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd">

  将*.hbm.xml中的<!DOCTYPE ....>的标签换成上面的<!DOCTYPE ....>标签内容

  之后就可以正常启动项目了

第二种情况:

解决:

hbm.xml中:

<!DOCTYPE hibernate-mapping PUBLIC "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
"http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd ">

在dtd后面有个空格,导致无法解析,将此空格去掉即可。
 

发布了22 篇原创文章 · 获赞 0 · 访问量 6760

猜你喜欢

转载自blog.csdn.net/djw745917/article/details/88375458