Skip to content

set max db connections for registry db in pre

Henri Philipps requested to merge hp-reg_db_pool into master

What does this MR do?

Set's registry DB pool maxopen connections to 5 in pre (instead of unlimited).

This should help with DB throughput and also give us a saturation metric. Per default, max connections is unlimited - this is setting it to 5 per instance (we just have a single core cloudSQL DB instance and usually 2 registry pods in pre).

We also set maxidle to 5, to prevent idle connections from being closed, so they can be re-used. Maxidle can never be higher than maxopen.

And we set maxlifetime to 5m to allow connections to be closed if they are not in use for a very long time.

See discussion here.

Author Check-list

Please read the Contributing document and once you do, complete the following:

  • Assign to the correct reviewer per the contributing document
  • Apply the correct metadata per the contributing document

Reviewer Check-list

  • Reviewed the diff jobs to confirm changes are as expected
  • Are there changes shown in the diffs unassociated with this MR? - This may require a rebase or further investigation
Edited by John Skarbek

Merge request reports