troubleshooting Question

C++ Posix Threads accessing DB Object from DB Connection Pool

Avatar of sriram
sriram asked on
Unix OSCAlgorithms
1 Comment1 Solution681 ViewsLast Modified:
Hello,
I have a requirement that the master thread in the server program creates POSIX worker threads dynamically upon the receipt of requests it receive. Each worker thread needs to do some Database Operation. For better performance we need to create a pool of Database connections at the time of server initialization and each worker thread requests for a DB connection from the pool. After the usage, the worker thread returns the DB connection back to the pool.

I would like to know the best algorithm being used for implementing Connection Pooling and synchronization. At any point in time DB connection is being used by only one thread.

I know Oracle supports Connection Pooling but unfortunately we are not using it.

Any help would be appreciated.

Thanks
Join the community to see this answer!
Join our exclusive community to see this answer & millions of others.
Unlock 1 Answer and 1 Comment.
Join the Community
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 1 Comment.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros