Skip to content
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

Use client.Reader to prevent starting Informer for Secrets #253

Merged
merged 1 commit into from
Apr 12, 2021

Conversation

ialidzhikov
Copy link
Member

@ialidzhikov ialidzhikov commented Apr 7, 2021

/platform gcp

After #112 I think that we have only one place where we explicitly interact with Secrets. This PR replaces the usage of a cached client with a client.Reader for the corresponding call to prevent having an Informer for Secrets under the hood.

I hope that this will improve the memory usage of the admission-gcp component.
Update: see #253 (comment)

Part of #143

Release note:

admission-gcp memory usage is reduced by not using cache for reading Secrets.

@gardener-robot gardener-robot added platform/gcp Google cloud platform/infrastructure needs/review Needs review size/xs Size of pull request is tiny (see gardener-robot robot/bots/size.py) labels Apr 7, 2021
@gardener-robot-ci-1 gardener-robot-ci-1 added the reviewed/ok-to-test Has approval for testing (check PR in detail before setting this label because PR is run on CI/CD) label Apr 7, 2021
@gardener-robot-ci-2 gardener-robot-ci-2 added needs/ok-to-test Needs approval for testing (check PR in detail before setting this label because PR is run on CI/CD) and removed reviewed/ok-to-test Has approval for testing (check PR in detail before setting this label because PR is run on CI/CD) labels Apr 7, 2021
@gardener-robot gardener-robot added the size/m Size of pull request is medium (see gardener-robot robot/bots/size.py) label Apr 7, 2021
@gardener-robot-ci-3 gardener-robot-ci-3 added the reviewed/ok-to-test Has approval for testing (check PR in detail before setting this label because PR is run on CI/CD) label Apr 7, 2021
@gardener-robot gardener-robot removed the size/xs Size of pull request is tiny (see gardener-robot robot/bots/size.py) label Apr 7, 2021
@gardener-robot-ci-3 gardener-robot-ci-3 removed the reviewed/ok-to-test Has approval for testing (check PR in detail before setting this label because PR is run on CI/CD) label Apr 7, 2021
Signed-off-by: ialidzhikov <i.alidjikov@gmail.com>
@gardener-robot-ci-1 gardener-robot-ci-1 added reviewed/ok-to-test Has approval for testing (check PR in detail before setting this label because PR is run on CI/CD) and removed reviewed/ok-to-test Has approval for testing (check PR in detail before setting this label because PR is run on CI/CD) labels Apr 7, 2021
@gardener-robot gardener-robot added size/xs Size of pull request is tiny (see gardener-robot robot/bots/size.py) and removed size/m Size of pull request is medium (see gardener-robot robot/bots/size.py) labels Apr 7, 2021
@ialidzhikov
Copy link
Member Author

I deployed this change on a large landscape and it improved the memory usage.

Screenshot 2021-04-07 at 17 10 36

The memory usage dropped from ~ avg 185Mi to ~ avg 118Mi.

@ialidzhikov ialidzhikov marked this pull request as ready for review April 7, 2021 14:26
@ialidzhikov ialidzhikov requested review from a team as code owners April 7, 2021 14:26
@rfranzke
Copy link
Member

rfranzke commented Apr 7, 2021

/assign @timebertt
/invite @timebertt

Copy link
Member

@timebertt timebertt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

@gardener-robot gardener-robot added reviewed/lgtm Has approval for merging and removed needs/review Needs review labels Apr 12, 2021
@timebertt timebertt merged commit 8a5ac5d into gardener:master Apr 12, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs/ok-to-test Needs approval for testing (check PR in detail before setting this label because PR is run on CI/CD) platform/gcp Google cloud platform/infrastructure reviewed/lgtm Has approval for merging size/xs Size of pull request is tiny (see gardener-robot robot/bots/size.py)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants