基于AOP与连接池的数据库访问优化设计与应用  

Optimal Design and Application of Database Access Based on AOP and Connection Pool

在线阅读下载全文

作  者:汪千松[1] 鲍陈[1] 

机构地区:[1]安徽工程大学现代教育技术中心,芜湖241000

出  处:《长春理工大学学报(自然科学版)》2013年第1期121-128,共8页Journal of Changchun University of Science and Technology(Natural Science Edition)

基  金:校青年基金项目(2010YQ050);高校省级自然科学研究项目(KJ2012B022)

摘  要:针对传统JDBC和EJB访问数据库效率不高,存在大量的数据库连接冗余的问题,设计并实现了一个基于AOP与连接池的数据库访问优化方案。该方案通过动态代理(Proxy)技术,实现对数据库连接进行独占控制,同时考虑到数据库连接的异常情况,加入了一种数据库重连机制策略,弥补现有连接池的不足;为了进一步提高数据库访问效率,提出了基于AOP的事务处理框架,解决业务层和数据存取中分离,实现数据的CRUD(创建、查询、更新和删除)操作。应用本方案有利于数据存取操作的重用和改动,改善了Web应用程序数据库访问性能,极大地提高数据库访问效率。Aiming at the low efficiency of traditional JDBC and EJB database access, and numerous connecting redundancy, we designed and implemented a database access optimization based on AOP and connection pool. The solution can realize a database connection for exclusive control through dynamic proxy technology. At the same time, considering the exceptional situation of database connection, a strategy which can reconnect the database is added. The strategy makes up the deficiency of existing connection pool. To further enhance the efficiency of database access, we propose a transaction processing framework based on AOP, which solves the separation of the business layer and data access and realize CRUD (Creation, Retrieve, Update, and Delete) operation.Application of the solution may benefit reusing and modification of data access, increase data access performance of Web application programs, and greatly improves the efficiency of database access.

关 键 词:AOP 连接池 动态代理 连接池管理 连接复用 数据库事务 

分 类 号:TP302[自动化与计算机技术—计算机系统结构]

 

参考文献:

正在载入数据...

 

二级参考文献:

正在载入数据...

 

耦合文献:

正在载入数据...

 

引证文献:

正在载入数据...

 

二级引证文献:

正在载入数据...

 

同被引文献:

正在载入数据...

 

相关期刊文献:

正在载入数据...

相关的主题
相关的作者对象
相关的机构对象