Database connections and related issues?
In general the max number of running sessions has a relation with the number of CPU cores on the database server. If you have 32 cores it does not make sense to allow more connections and expect them all to run concurrently.
Because in most of the times there will be some waiting, you could allow a few more but the database system itself also needs some CPU to work for you.
So your database connection pool should not have many more connections than there are available CPU cores to run them on.
When all CPU's are loaded, the application will have to wait for connections to return results and putting more stress on the database will slowdown the application more.
The optimal connection pool size can be smaller but depends on the transaction length and the number of concurrent transactions. If every transaction returns it's connection to the pool the system can handle a lot of work.