i’m using Play 2.6 with Ebean and HikariCP. For my staging environment i’m using AWS and their great Aurora Serverless MySQL Database. If there are no connections to the database, the database is going to sleep and incur no costs during that time. This is great for staging and testing environments, because you only pay, when you are actually using the ressources.
However using Play, there are constantly like 15 connections to MySQL (as configured in HikariCP). Is there a way to configure it so, that the connection to the database is not persistent, like with PHP? Say if the connections are idle for 10 minutes, they are closed and a new connection is opened, only when there is actually a user request?
That would be great, otherwise i would have to pay the minimum of 100$ / month for the MySQL Server.