使用c3p0就不能获取集合了
//hibernate的配置如下
<property name="hibernate.connection.driver_class">com.microsoft.jdbc.sqlserver.SQLServerDriver</property>
<property name="hibernate.connection.url">jdbc:microsoft:sqlserver://localhost:1433;DatabaseName=skynet</property>
<property name="hibernate.connection.username">sa</property>
<property name="hibernate.dialect">org.hibernate.dialect.SQLServerDialect</property>
<property name="hibernate.c3p0.max_size">100</property>
<property name="hibernate.c3p0.min_size">5</property>
<property name="hibernate.c3p0.timeout">3000</property>
<property name="hibernate.c3p0.max_statements">100</property>
<property name="hibernate.c3p0.idle_test_period">3000</property>
<property name="hibernate.c3p0.acquire_increment">2</property>
<property name="hibernate.c3p0.maxIdleTime">1800</property >
<property name="hibernate.c3p0.validate">true</property>
<property name="connection.provider_class">org.hibernate.connection.C3P0ConnectionProvider</property>
<!-- <property name="hibernate.show_sql">true</property> -->
<mapping resource="com/xml/repair.hbm.xml"/>
可以增加··可以获取对象,就是不能获取集合,没加c3p0之前,一切都好
------解决方案--------------------好好看看代码吧,我用c3p0好几年了,从没出现过问题。
------解决方案--------------------