generated from crossplane/provider-template
-
Notifications
You must be signed in to change notification settings - Fork 91
Use native Golang connection pooling to reduce number of connections opened for postgres (#195) #239
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
ajcaldera1
wants to merge
10
commits into
crossplane-contrib:master
Choose a base branch
from
ajcaldera1:ac-issue-195
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…trib#232) Bumps google.golang.org/protobuf from 1.31.0 to 1.33.0. --- updated-dependencies: - dependency-name: google.golang.org/protobuf dependency-version: 1.33.0 dependency-type: indirect ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Signed-off-by: Alan Caldera <30800723+ajcaldera1@users.noreply.github.com>
* fix: enable management policies Signed-off-by: Jesús Fernández <7312236+fernandezcuesta@users.noreply.github.com> * fix: linter Signed-off-by: Jesús Fernández <7312236+fernandezcuesta@users.noreply.github.com> * chore: offload lint changes to crossplane-contrib#216 Signed-off-by: Jesús Fernández <7312236+fernandezcuesta@users.noreply.github.com> * chore: revert changes as per peer review Signed-off-by: Jesús Fernández <7312236+fernandezcuesta@users.noreply.github.com> --------- Signed-off-by: Jesús Fernández <7312236+fernandezcuesta@users.noreply.github.com> Signed-off-by: Alan Caldera <30800723+ajcaldera1@users.noreply.github.com>
…#236) * chore: remove duplicate entry of golangci version Signed-off-by: Jesús Fernández <7312236+fernandezcuesta@users.noreply.github.com> * chore: bump up versions for crossplane 1.20 Signed-off-by: Jesús Fernández <7312236+fernandezcuesta@users.noreply.github.com> * chore: restore changes Signed-off-by: Jesús Fernández <7312236+fernandezcuesta@users.noreply.github.com> --------- Signed-off-by: Jesús Fernández <7312236+fernandezcuesta@users.noreply.github.com> Signed-off-by: Alan Caldera <30800723+ajcaldera1@users.noreply.github.com>
…e before mutating it. This will help cut down the number of ALTER ROLE statements that would otherwise needlessly fire for each role. Signed-off-by: Alan Caldera <30800723+ajcaldera1@users.noreply.github.com>
…on of kubectl. Signed-off-by: Alan Caldera <30800723+ajcaldera1@users.noreply.github.com>
Signed-off-by: Alan Caldera <30800723+ajcaldera1@users.noreply.github.com>
Signed-off-by: Alan Caldera <30800723+ajcaldera1@users.noreply.github.com>
Signed-off-by: Alan Caldera <30800723+ajcaldera1@users.noreply.github.com>
Signed-off-by: Alan Caldera <30800723+ajcaldera1@users.noreply.github.com>
Signed-off-by: Alan Caldera <30800723+ajcaldera1@users.noreply.github.com>
Collaborator
|
I think you could drop all commits in this branch and run git cherry-pick 24a83a01cfcf758c580bf7930301d256d4d32781git fetch upstream # or origin
git rebase -i upstream/master # or origin/master
# and then remove all commits except the last one |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description of your changes
This change reduces the number of connections that must be opened to support a reconciliation job. On execution of New() it opens a connection pool with a maximum of 5 connections (hard-coded in this iteration) with a max lifetime of 10 minutes. After 2 minutes, any idle (unused) connections will be terminated to a minimum of 2 connections. These connections are then reused across the entire lifecycle.
Fixes #195
I have:
make reviewableto ensure this PR is ready for review.How has this code been tested
e2e tests done and tested by production observations over the last 7 months.