While creating a release from UI in Octo for a project which has 29 different packages to deploy, our DB connection pool got exhausted and we started seeing following error:
“Timeout expired. The timeout period elapsed prior to obtaining a connection from the pool. This may have occurred because all pooled connections were in use and max pool size was reached.”
Another part of logs:
ERROR There are a high number of transactions active. The below information may help the Octopus team diagnose the problem:
there were 98 such queries listed in the logs, even though we had only 29 packages in the project for single release. We get these timeouts only when we try to create the release from UI, as it tries to get details about all packages required for the release.
I understand we can increase Pool limit to avoid such issue, but I was hoping to have some logic from app itself to not initiate these many request or basically fine tune the logic with some batch/paging process.
Master server details:
Octo version: 2020.2.15
Instance type: C5.2xlarge
number of nodes in cluster: 1
task cap: 50
DB connection pool limit: 200
Also if there is any guideline/relation between task cap and DB connection pool limit, I would like to go through that.
Thanks and Regards,