hibernate停止清理连接池

时间:2018-01-27 11:46:26

标签: java spring hibernate

hibernate连接在清理连接池时停止,它不会进展!

enter image description here

我的hibernate.cfg.xml

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE hibernate-configuration PUBLIC "-//Hibernate/Hibernate Configuration DTD//EN" "http://www.hibernate.org/dtd/hibernate-configuration-3.0.dtd">
<hibernate-configuration>
  <session-factory>
    <property name="hibernate.connection.driver_class">com.mysql.jdbc.Driver</property>
    <property name="hibernate.connection.url">jdbc:mysql://localhost:3306/eshop_db</property>
    <property name="hibernate.connection.username">root</property>  
    <property name="hibernate.show_sql">true</property>
    <property name="hibernate.dialect">org.hibernate.dialect.MySQLDialect</property>
    <property name="hibernate.current_session_context_class">thread</property>
    <property name="hibernate.hbm2ddl.auto">create</property>


    <mapping class="ma.eshop.Entity.Article"/>
    <mapping class="ma.eshop.Entity.Client"/>
    <mapping class="ma.eshop.Entity.Client_Cmd"/>
    <mapping class="ma.eshop.Entity.Client_Cmd_Pk"/>
    <mapping class="ma.eshop.Entity.Commande"/>

  </session-factory>
</hibernate-configuration>

0 个答案:

没有答案