The PostgreSQL JDBC Driver is now PgBouncer compliant

Three years ago a discussion was launched on the Pgbouncer mailing-list [1] about the JDBC Driver which does not disable prepared statements when using ?prepareThreshold=0 in the connection string.

At Clever Cloud, we provide PostgreSQL databases behind PgBouncer to handle pools of connections. And to optimize these pools, we use the transaction pooling mode. This mode will prevent clients from using prepared statements as the session is only used for one transaction.

To be able to use this mode internally we manually applied a patch to the driver. After 8 months of inactivity, the pull-request [2][3] was finally merged into the master branch of the driver.

Now we hope that the next version will be released soon.

References:

[1] http://lists.pgfoundry.org/pipermail/pgbouncer-general/2010-February/000507.html [2] https://github.com/pgjdbc/pgjdbc/pull/9 [3] https://github.com/pgjdbc/pgjdbc/pull/58

Blog

À lire également

SuperBOL: The COBOL revolution in the Cloud

COBOL, a programming language that is over 60 years old, continues to power a large proportion of the IT systems of the world's major companies, particularly in the financial and insurance sectors.
Features

Clever Cloud welcomes the first startups to the UP Programme

Clever Cloud is proud to announce the arrival of the first five startups selected to join its UP Programme, an initiative dedicated to supporting young technology companies in their growth phase.
Company

A minor update resulted in a cascade of errors: how it went wrong, what we’ve learnt

On Friday, August 2nd, 2024 Clever Cloud’s platform became very unstable, leading to downtime of varying duration and scope, for customers using services on the EU-FR-1 (PAR) region, and remote zones depending on the EU-FR-1 control plane (OVHcloud, Scaleway, and Oracle). Privates and on-premise zones weren’t impacted.
Company Engineering