hibernate数据库连接池参数详解

C3PO是一个数据库连接池,Hibernate可以配置为使用C3PO连接池
hibernate.c3p0.max_size最大连接数
hibernate.c3p0.min_size初始连接数
hibernate.c3p0.timeout数据库连接对象最大持有时间(以秒为单位)
hibernate.c3p0.max_statements最大可缓存数据库语句对象,设为0则不缓存
hibernate.c3po.acquire_increment当连接池耗尽并接到获得连接的请求,则新增加连接的数量
hibernate.c3p0.idle_test_period在连接空闲多少秒后,检查连接
hibernate.c3p0.validate检查连接,推荐使用hibernate.c3p0.idle_test_period代替,默认值为false

猜你喜欢

转载自love5811.iteye.com/blog/1542244