C3p0 vs. bonecp

Source: Internet
Author: User

Some colleagues recommended bonecp. The results of searching benchmark on the Internet were amazing. Recently, I used the connection pool to change it to bonecp. However, after my own use and testing, I switched back to c3p0 for two reasons:

1. bonecp is less stable than c3p0 in high concurrency, and other identical conditions (web layer jersey, data layer PostgreSQL ), when bonecp is used, the fluctuation of throughput measured multiple times is significantly greater than that of c3p0. At the same time, there is no essential difference between the two in terms of performance, and there is no obvious victory in bonecp, the connection pool of c3p0 is warmer or faster.

2. bonecp datasource does not support automatic reconnection (maybe I did not find it), which is terrible. I manually restarted the database during the test and c3p0 reconnected normally, bonecp is completely unresponsive.

As far as I know, oschina once tried to switch to bonecp. Later, it was said that it had changed back because of some bugs. My own feeling is similar. Even if bonecp claims to use the updated concurrent feature, so it has better performance, my own results are not very consistent with it.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.