Application vs Database Resident Connection Pool

元气小坏坏 提交于 2019-12-13 13:38:23

问题


Situation: I have a requirement to use connection pooling while connecting to Oracle database in python. Multiple python applications would use the helper connection libraries I develop.

My Thought Process: Here I can think of two ways of connection pooling: 1) Let connection pool be maintained and managed by database itself (as provided by Oracle's DRCP) and calling modules just ask connections from the connection broker described by Oracle DRCP.

2) Have a server process that manages the connection pool and all caller modules ask for connections from this pool (like dbcp?)

What suggestions do I need: option 1) looks very straight forward since pool does not need to be stored by application. But I wanted to know what advantages do I get other than simplicity using option 1)? I am trying to avoid option 2) since it would require a dedicated server process always running (considering shelving is not possible for connection objects). Is there any other way?


回答1:


Let the database handle the pool. . . it's smarter than you'll be, and you'll leverage every bug fix/performance improvement Oracle's installed base comes up with.



来源:https://stackoverflow.com/questions/19848191/application-vs-database-resident-connection-pool

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!