oracle session 不断增加,如何清除session,大部分status='INACTIVE'. 服务期效率不断下降!
application用的是hibernate连接.我用的是
get session: session = HibernateSessionFactory.getSession();
close session : HibernateSessionFactory.closeSession();
application用的是hibernate连接.我用的是
get session: session = HibernateSessionFactory.getSession();
close session : HibernateSessionFactory.closeSession();
SSH、Ant、IBatis、jsf、seam、portal、设计模式、
ZK、DWR、ajax、CSS、oracle
群号:65670864 欢迎加入
1)不断打开的数据库连接
2)打开连接后,长时间的大事务处理,导致连接不能尽快释放
3)忘记关闭连接解决办法:
1)任何事务完成后,记住关闭连接
2)大事务改小事务
3)增加oracle其他资源,加快oracle系统处理速度。sga_target=1/2物理内存,pga_aggregate=1/4物理内存,db_writer_processes=2~4。
4)在应用端使用连接池。
5)增加硬件资源:cpu,ram.