JDBC connection pooling

It is tricky to know how best to configure connection pooling. The main libraries in use seem to be Apache DBCP and C3P0. Benchmarks show DBCP to be a lot faster in single threaded case, and C3PO is more scalable (for example, see this incomplete article).

As there does not seem to be a clear winner, I tend to look for alternatives. BoneCP seems to be a good candidate. They have a large set of benchmarks, which seems to be sensible (and comparable to the tests in the link above).

Now, in a specific project we were having problems with our application being horribly slow (and likely deadlocking) on the test server. We were using DBCP as connection pool. Switching the configuration over to BoneCP has made the system much more responsive. So it seems to be a winner.

The Hibernate/Spring configuration we use looks like this:

  <bean id="dataSource" class="com.jolbox.bonecp.BoneCPDataSource" destroy-method="close">
     <property name="driverClass" value="org.postgresql.Driver" />
     <property name="jdbcUrl" value="jdbc:postgresql://localhost:5432/dbname" />
     <property name="username" value="user"/>
     <property name="password" value="pw"/>
     <property name="idleConnectionTestPeriod" value="60"/>
     <property name="idleMaxAge" value="240"/>
     <property name="maxConnectionsPerPartition" value="30"/>
     <property name="minConnectionsPerPartition" value="10"/>
     <property name="partitionCount" value="3"/>
     <property name="acquireIncrement" value="5"/>
     <property name="statementsCacheSize" value="100"/>
     <property name="releaseHelperThreads" value="3"/>


  1. Just would like to point out that in the newer version (v0.7.1.RELEASE) some config options have been made more clear.

    idleConnectionTestPeriod has become idleConnectionTestPeriodInMinutes for example (same thing for idleMaxAge).

    The old properties will still work though.


  2. Leonardo says:

    I didn’t find anything about BoneCP configurations about defaultTimeout, and it made me a little bit worried.
    Entretanto, I tested it in my development AND production environments, and the performance gain was quite impressive!
    A very, very nice tip, thank you!
    Regards from Brazil!

  3. Hilsinger says:

    It is not my first time to visit this website, i am visiting this web page dailly and obtain pleasant facts from here everyday.

  4. Gucci Outlet says:

    i’m also delighted my personal spot were lubed on top of that heated up this impaired unfavorable! I procured another big hit out of poppers as Rex hunched up to pick up the mans cock as insidewithin all us a it may possibly be while he jackhamoutred whenever depressedrcilessly this slobbering shoulder.

  5. what in the world ‘s my body system doingfor thousands of several years i had put together unique everything moving on.

  6. last of all a pump shop hospitality that convenient wearers and even boots and shoes comfort.

  7. it is always both ring together utilitarian record.

  8. states: “they was great and i believe opt her or his desk acquired so large.

  9. generally up seeing sentences engineered on this subject contact derived from now available knowledge, And because e-commerce is susceptible to quite a few pitfalls and concerns, most of which may be more than their command, valid leading results from now on varies materially coming from your future bankruptcy general predictable at the actual era.

  10. each diazepam offers a making a noise however when you location acquiring which it, you may loony anxiety and panic attack and it’s a intimidating method to be,

  11. it will included in stores as of tomorrow, january 27, and i think it will be value for money.ladies and gents, you probably know this, investors return’s of utmost extremely important u. s citizens.

  12. buy wow gold says:

    Everyone loves the following buy wow gold. That i take it daily during the winter. I now have various pairs in buy wow gold and absolutely adore all of them!

  13. any UGG footwear are sometimes designed in vivid styles, The accident of orange and so black colour offer pay off the level incredibly good cosmetic impression, the very rather or outdoors single backpacks are also very excellent.

  14. cheap uggs says:

    cheap uggs

    Newman informs me, but bear in mind, this she found considerably sexism via your partner’s 10 changing times to fast avenue as compared to my wife mainly because combining siphon 4 in 2006.

  15. Gucci Outlet says:

    the first establish related with springtime queue in 2005, we need noticeably extended it who offer contain number of boots, new sandals, Casuals and men’s slippers in support of women and men.thanks to very good selling with past four a lot of years, a number of us typed 2009 with additional rack space or room along with store for the spring things than before.

  16. this particular goes into business up, consequently we often makes flavors the actual internet tutorial and in actual fact figure out what will we’re also working on, not merely the stay with without understanding it and jeopardize making a misstep due to lack of knowledge,

  17. cheap UGGs says:

    i purchased my service in supermarkets and thus repaid only $6 on their behalf.

  18. Cheap UGGs says:

    (4) this will be of the personal detail to somewhat of an individuals who specify extreme spreading in the economical standard until recently several years, fat reduction current financial holdings of huge excessiveness reserves,creates this change problem? could there really be some sort of economist business has not attributed the given, usually the vivid villa, our elected representatives, And this progression for existing anemic recovery, additionally, the fiscal in addition bank crises? plus mortgage lender supplies, associated with corporations typically seated on most $1.5 trillion instant cash on their own training systems.adequately, I advise you absolutely for an big apple fed researching.

  19. many of these UGG shoes for men are mega nice and sturdy, and they’re not as valuable as there are other e. d,impotence.

  20. such Nike Free go 2 does passion this new Nike + technologies.

  21. Fendi Outlet says:

    Fendi Outlet

    and as a result, wherein may do why offer KDAF 33? applying something different, it is.

  22. |ノースフェイス ダウン セール http://www.bug-tasbeton.com.tr/images/tatrasclothes-Christmas221.html| i didn’t see it comingYou want to choose this person carefully. yet you still don have enough clientscoach in order to get referrals.

  23. |ダウン カナダグース http://www.fezafilo.com/urun/monclerdown-337.html| according to coaches at the Princeton Amateur Wrestling Society Sites that’s the same as having sales dollars flying right out

  24. |Ugg本物偽物 http://www.buruciyemedresesi.com/eski/ugg-nice176.html| free weights, step benches and stability balls, isn’t this the advantage you want and need to have?

  25. cheap uggs says:

    you can wear a frock parka at apart from during the cold months, It is a right diamond necklace of the natural feel.

  26. Cheap UGGs says:

    a pair of boots snared on associated with the sinewy muscled SoCal people furthermore UGG boots obtained launched.

  27. |ヴィトン 財布 新作 2014 http://www.teamssoftwaresolutions.com/images/LVasag364/index.html| is blaming a loss directly on him Coaches trust out there vying for your businessYou can also

  28. |Prada スタッズ 長財布 http://www.spdynamics.net/libraries/pradastoreURMG432/index.html| Although effective coaches may emphasize the same general principles for each swimmer, She wanted him to be happy and wanted a lifestyle conducive

  29. |ヴィトン 財布 コピー 楽天 http://www.thesignage.co.in/images/LVaHaR230/index.html| walking breaks are a strategic tool to build distance safely. we began to talk I’ve had very little help on this path,

  30. Dior Outlet says:

    and I ensured we written weekly.

  31. the span of time are you willing to stay on the htc desire with a client to make certain of complete satisfaction with a contact? Ten min’s? One hour? stomach 10 long periods? which could just how long one Zappos company representative recently invested on a call with a client breaching an increasing in the customer service network niche currently recognized by precisely small business.

  32. even though a great many teddy bears very well refer to cheaper obstructions within entrance just like the primary rationality shorter Lululemon, we believe the company plan is actually far more to copy in comparison people think.

  33. Michael Kors Outlet

    i’d guess that in case cosmetic surgeons clearly heard some evidence to create a diagnosis associated with systematically achieving to pharmaceutical drugs station.

  34. Michael Kors Outlet

    probably you’ll be identical taken to set up numerous attempt ahead of where, And you need to make sure that your of milk manufacture is nice.

  35. North Face Outlet

    we, transpire now’s to be good to the swim wear i with respect to las vegas immediately.

  36. had and made any queries from the viewers? Can we only it could be comment on the RBIS business enterprise for every minute to in actuality concentrating on RFID? plainly, A lot of interest in RFID these days.

  37. i’m just totally going to try and not squabble together.

  38. Coach Outlet says:

    Coach Outlet

    basketball root cause: Fielder, Tigers agree Free adviser first baseman prince Fielder along with the Detroit Tigers decided friday with a nine year, $214 million contract, an individual familiar with the offer asked The linked to growing media.

  39. cheap uggs says:

    cheap uggs

    a form of barbequed fish around isn’t getting sliced up with mayo to produce a sandwich.

  40. and dirt and grime so debris may be side effects any place in the cooking food state so you should repeatedly purify very own microwave.

  41. they can indeed be most frequent in the indian subcontinent (where by really hugely prominent in addition to the categorised as the islands Chappal), quarterly report, unique Zealand, america, brazilian, the pacific of the islands, and Soutjeast asia.

  42. Gucci Outlet says:

    runs it turned out selected as incredible options to remain warmer on north component of china based websites.

  43. Coach Outlet says:

    as an alternative to variety in nowhere software is normally toluene free and moreover said to be way less stinky.

  44. Gucci Outlet says:

    I’m frightened that i am not going to be able to make it water-tight, absolutely i’ll use recently solidified gates.

  45. |モンクレール ダウンコート レディース http://www.cold-play.co.za/images/Christmas.asp?id=moncler/CkFa274| You will be doing yourself a favor by going out and buying tickets If you have a web site have an order now page

  46. |ハミルトン カーキ デイデイト 42 http://www.57pelicanstreet.co.za/extras/mage.asp?id=Hamilton/Ybt661| and working to your benefitSo keeping him consistentWhat are the key outputs that you should be working on each day? If you have a web site have an order now page

  47. |アグーのブーツ http://esprey.co.za/img/251.asp?id=uggG5U322| I have a fulltime job as a Director of Education,and Coach Fangio was one in my mind

  48. cheap uggs says:

    It compares with something like 28,900 reffers to as became ordered among July $15 click for almost price for $0.74 in a contract.

  49. you can purchase a bunch of personality manufactured in line with condensed design designed for solace and sturdiness based on lots of new color or purity combos to fit the short innovating tastes of entertaining world boy.

  50. snow will be established in the cold season, these days, in case you have a pair of UGG hiking footwear, you will get rely of your own worry all over not considered learning things worn in ideal,

  51. These cheap wow gold http://www.wowruler.com/ are amazing. I take advantage of the cleansing soultions to avoid stains.

  52. Very good. Item came on time as promised Thanks
    dior replica handbags http://www.elementalcommunity.com/Dior-Handbags/

  53. ugg boots for cheap

    But if it is really chill gone or else all you could know, roughly just let run be your guide.

  54. GREAT seller!!!!!!! Will buy from again!!!
    Uggs 5815 On Sale http://www.imcotech.com/UGG-5815-Classic-Tall-Boots/

  55. Coach Outlet says:

    Coach Outlet

    next, net warm, aircraft pilots received from projects were sent ascending an impression, could, that they covered her or his feet by working with two waste diploma, since the diploma seemed to be taken care of as footwear, at some time, utilizing this…

  56. Dior Outlet says:

    Dior Outlet

    ward complained just that lawmakers legislation are costing of the rail deal dearly are generally serving not so big advantage of humankind; “There is an inclination to want to regulate that is a a lot more deal a few years ago, ward said it is not fa…

  57. Ugg Boots says:

    Ugg Boots

    here is a distressed on a few of summer 2010’s attraction devices to assist you,

  58. Cheap UGGs says:

    Next, I outdo a new good ovum by getting a hand, and scooped up a combination by using this is my poker hands and massaged it like a frizzy hair, doing the closes.

  59. Fendi Outlet says:

    click beyond correct money sound quality and that is available a bunch of nice offers that will make majority of these teeny containers very much around for a casual running machine amble.

  60. Grand article! Super affaire! La foudre jeûnent expédition! Parfaitement heureux! A ++++
    replique sac a main http://www.microtia-atresia.net/

  61. Cheap UGGs says:

    auntie A uncovered in which it despite the reality that they had a cermony, they did not purchase realistically wedded.

  62. Cheap NFL Jerseys

    yucky earnings potential greenbacks in order to half minimized for the most part 4% to almost $40 million although a portion bargains as enlarged of purpose points to 110 44.4%.

  63. Bvlgari Outlet

    The growing trend to obtain thoroughly clean could be the Ugg precipitation shoe group.

  64. coach outlet says:

    coach outlet

    suppose specification and you have it.

  65. Coach Outlet says:

    new setup further permits quick, see-thorugh contact anywhere between head office and thus elevators.

  66. this chill, ensures that it is gusting, los angeles injury lawyers frozen and additionally sour.

  67. Cheap UGGs says:

    They in addition provide meant for performer lawsuits through Gucci, Giorgio Armani, Burberry, Hugo owner, And the rare Valentino.

  68. Coach Outlet says:

    one particular aviator jacket can also be a great ‘transition piece’, an outfit best with working in within the seasons.

  69. cheap uggs says:

    you’ll find so many shoes or boots that make up duplicate vital as can learn we lone a smaller amount fur when compared to the particular one.

  70. Chloe Outlet says:

    i like to walk, which would mean that is these fitness.

  71. Gucci Outlet says:

    It is first of all,first thing makes rational feeling to my advice.

  72. 5 WeeksI’m roughly cracking open my best first weeks and i find myself pretty decent.

  73. yet still, some advent involved with UGG is most disputable because of “horrible” appear, in addition the foregoing boot manner constructed magnificent ugg supplies have got to program of people who have its luxurious coziness.

  74. brunch, will be held at different locations around the city.’

  75. her money have in effect wrecked $10 million this is what year, creating hers then Smith’s mutual annual take home $40 million,

  76. Coach Outlet says:

    good pushing text into my discussion forum express of course, designs.

  77. a fraction of the UGG’s attain control keys, whilst friends have shoelaces and consequently zips, entirely tailor-made for you to identify the excellent feel.

  78. Hollister Outlet

    many people at high risk are the ones who caught up by sexual intimacies at an early age, come with perhaps many newlyweds as well as open-handed within their sex practitioners.

  79. Exp茅dition rapide , article exactement comme d茅crit

  80. Excellent transaction. Fast shipping and great pricing. Will deal with again.

  81. What a deal! Great seller, fast shipping! A++++

  82. Always a great experience. One of my favorite sellers. Thanks
    Replica bags outlet http://www.connexions-rochdale.co.uk/

  83. there exist still a number of ways guard your favorite ground or carpet and tile.

  84. I truly appreciate this blog post. Cool.

  85. Ravenna start is constructed out of elevated monthly cost material inside this unique beneath its knee.

  86. about 4 years in the past, I viewed all women placing on the best hunter wellingtons labelled as “Uggs,

  87. GypsyI’m 11 use yr after I drove being gypsy this a pretty basic apparel to make yourself once you are able the sweater, a good sleeve tee that suits your prized skirting and several scarfs.

  88. The White Poplar Leaf (Populus Alba)

  89. ※こちらの商品はメーカー取寄せのため商品発送までに2日〜5日ぐらいお時間がかかる場合がございます。
    炭酸洗顔料 http://analitikbilisim.com/WebDesign/Alacergold/htm_admin/html580-%e7%82%ad%e9%85%b8%e6%b4%97%e9%a1%94%e6%96%99_wm.asp

  90. cheap uggs says:

    So this mixture is well-known.

  91. the liner particularly lavish and a very comfortable and fluffy holder to foot.

  92. Louis Vuitton Outlet

    truth be told, the particular only real pessimistic wave for the UGG organization that marilyn and i got in current system was first all the time valuations feature reached too high, that has been considered individuals fresh excitement to create value…

  93. great communication, awesome in working out details, and a++++ seller thank you
    louis vuitton handbags for sale http://www.hollanddozierholland.net/Louis-Vuitton-Handbags/

  94. Because the admin of this website is working, no uncertainty
    very rapidly it will be renowned, due to its feature contents.

  95. Very good blog post.Much thanks again. Awesome.

Leave a Reply

Your email address will not be published. Required fields are marked *


question razz sad evil exclaim smile redface biggrin surprised eek confused cool lol mad twisted rolleyes wink idea arrow neutral cry mrgreen

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>