I'm trying to use Squeryl in a new Scala project. This is my first project in Scala, so I'm looking for a good Scala library to handle connection pooling. Of course I might as well use a Java library. What would be a best fit for SQueryl? Amongst java libraries I'm considering DBCP, C3P0, Proxool and BoneCP, being 开发者_如何学PythonBoneCP a serious candidate looking at their benchmarks.
I've used C3P0 in production for many years, always been rock solid for me. Watch out with your DB driver tho, they can be very flaky.
I wrote a blog post about db connection pooling with slick you may find useful:
http://fernandezpablo85.github.io/2013/04/07/slick_connection_pooling.html
I know this is an old post, but to keep the answer current, if you need a connection pool and you're writing an application that runs on the JVM, I suggest HikariCP.
精彩评论