How do I prevent the Hibernate connection pool from throwing the connection limit exception?

1

I have a stateless DAO using JPA that uses the Hibernate connection pool to apply its transactions to the database. Whenever Hibernate entityManager starts, I have the following line in the console of my server:

Hibernate connection pool size: 20 (min=1)

If I have more than 20 clients asking for transactions at the same time, hibernate throws an exception on the limit number of connections. Should I handle this problem manually or does hibernate have some functionality that allows you to stack requests and distribute free connections to standby clients?

    
asked by anonymous 07.09.2017 / 08:10

0 answers