Questions tagged [connection-pooling]

In software engineering, a connection pool is a cache of connections maintained so that the connections can be reused when future requests to the resource are required.

Description

Connection pools are used to enhance the performance of executing commands on a database or other server. Opening and maintaining a connection for each user especially requests made to a dynamic database-driven website application, is costly and wastes resources.

In connection pooling, after a connection is created, it is placed in the pool and it is used over again so that a new connection does not have to be established. If all the connections are being used, a new connection is made and is added to the pool. Connection pooling also cuts down on the amount of time a user must wait to establish a connection to the resource.


Connection Pool libraries

Java

  • HikariCP
    It is considered as one of the best libraries for connection pooling. Play 2.4 Framework uses HikariCP by default.
    Website, GitHub.

  • BoneCP
    It beats older connection pools such as C3P0 and DBCP but should now be considered deprecated in favour of HikariCP.
    Website, GitHub

  • Apache Commons DBCP
    Website.

  • C3P0
    Website, GitHub

3263 questions
1
vote
1 answer

error "No node was available to execute the query" while using MCS service of AWS

after some time we got error: 2020-03-30 14:09:45 +0000 [http-nio-12082-exec-10] ERROR c.i.i.c.u.c.GenericCassandraDao 2fcc2418-2a0f-401e-b51f-b57fc0b305ea - Error in inserting data for tenant code: anne2020-03-30 14:09:45 +0000 …
1
vote
1 answer

ConnectionPool: pool is empty - increase either maxPoolSize or borrowConnectionTimeout

I was facing this issue for my springboot application that connects to a DB and MQ, and uses Atomikos Transaction manager. com.atomikos.jms.AtomikosJMSException|Connection pool exhausted - try increasing 'maxPoolSize' and/or…
Praveesh P
  • 1,399
  • 2
  • 25
  • 42
1
vote
1 answer

create a connection pool for many DBs on the same DB server (Spring Boot)

I'm looking for a way to create a connection pool for many DBs on the same DB server (PostgreSQL Aurora). This means that I need the ability of changing the target DB of a connection at run time. Currently I'm using HikariCP for connection pooling,…
1
vote
0 answers

Query sent from nodejs server to postgres never times out

I have a SQL query that I am sending from the server side of my application and it seems to never time out. I am doing set statement_timeout TO 30000 in the beginning of my query, but that never works. Here is an example query: set statement_timeout…
fairlyMinty
  • 413
  • 8
  • 22
1
vote
1 answer

Couchbase BucketClosedException while bucket is being used actively

CB server- Enterprise Edition 6.0.0 build 1693 CB Java sdk- 2.7.10 I’m running stress test on my CB cluster, where I’m generating load of up to 1k ops/sec. The load is a mix of set/get operations. The 2 operations are fairly equal in number. The…
1
vote
0 answers

Reactor Netty - Change of behavior in connection pool metrics

When I switch to Reactor-Netty 0.9.5.RELEASE (Spring Boot 2.5.RELEASE), connection pool metrics aggregation change. I use a named connection pool, as for example: ConnectionProvider.create("a_name", 100); When I look at metrics, it seems I get a…
1
vote
0 answers

Multi tenant database connection pool for multiple databases

How I can create multi tenant database connection pool for multiple databases. So basically I want to create connection pool at Instance level(don't want to create connection pool for every database) and according to request i'll ask connection for…
SANDHYA SINGH
  • 151
  • 2
  • 8
1
vote
1 answer

Kill all sleeping mysql pool connections using node

I am using node for my project and using connection pooling, whenever I query show processlist I found more than 200 sleep connections even though i am releasing it after every query like this- return new Promise((resolve, reject) => { …
ADITYA HAZARIKA
  • 300
  • 1
  • 4
  • 13
1
vote
3 answers

Connection Pooling for My Custom Application

In my Project i have a server application and a client application and one mediator application.Client communicates with the server through the mediator application.The mediator application inturn connects to the server application. For Every client…
Dungeon Hunter
  • 19,827
  • 13
  • 59
  • 82
1
vote
1 answer

HHH10001002: Using Hibernate built-in connection pool (not for production use!)

While Deployment of my application i got this hibernate warning (twice): WARN org.hibernate.orm.connections.pooling - HHH10001002: Using Hibernate built-in connection pool (not for production use!) I don't want to use either these built-in…
ban
  • 23
  • 1
  • 4
1
vote
0 answers

Whats the connection pool size for a single instance of HttpClient, Where can i see it in Docs?

since Http Client should be instantiated once to reuse across application life time, it definitely maintains a connection pool, right? Whats the size of this connection pool? The HttpClient class instance acts as a session to send HTTP requests. An…
Sana.91
  • 1,999
  • 4
  • 33
  • 52
1
vote
0 answers

Implement pool queue selenium grid

In automation test single Cucumber TestNG runner is assigning threads to grid properly. However when we have multiple jobs accessing same hub url, it's causing time out. If we implement a pool queue, Do I need to queue testNg runner class or…
1
vote
0 answers

How to implement pool for selenium hub requests

We have recently created a job with cucumber selenium grid on aws, which will scale pods on fly up to 100. Cucumber has inbuilt parallel feature for testNg in latest version. If we have 100 nodes and 150 tests(In one job) then 100 tests in that job…
1
vote
0 answers

Get TelemetryClient in DbContext provided by DbContextPool

When adding a DbContext to your service container via AddDbContextPool, it appears that you can only use a constructor with a single argument of DbContextOptions. To get a TelemetryClient in .NET Core 3+, it is NOT…
1
vote
1 answer

connection Pooling in Apache Tomcat 6 causes website to hang until tomcat is restarted again

After configuring connection pooling the website seems to hang up after a period of time but it executes faster otherwise.. Is connection pooling the cause for the same? When the website stops responding then a tomcat restart reverts back the…
KronnorK
  • 539
  • 5
  • 17