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

[GEP-7] Don't add entries with empty data in ShootState #2694

Merged
merged 1 commit into from
Aug 12, 2020

Conversation

plkokanov
Copy link
Contributor

How to categorize this PR?

/area control-plane-migration
/kind enhancement
/priority normal

What this PR does / why we need it:
Previously the ShootState contained entries which don't actually have any data e.g.:

- data:
       certificate: null
       privateKey: null
   name: kubecfg
   type: certificate

This PR makes it so that when trying to extract infodata from existing secrets and the secrets do not contain any data which has to be saved, these empty entries are not added to the ShootState.

Which issue(s) this PR fixes:
Fixes #

Special notes for your reviewer:

Release note:

Entries with empty data are no longer added to the ShootState.

Copy link
Member

@rfranzke rfranzke left a comment

Choose a reason for hiding this comment

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

/lgtm
/needs second-opinion

@rfranzke
Copy link
Member

/invite @swilen-iwanow @vlvasilev

@swilen-iwanow
Copy link
Contributor

Should we take care of the empty entries already in the ShootState somehow. I think the pr doesn't remove them, right?

@plkokanov
Copy link
Contributor Author

The empty entries currently don't cause any errors.
Furthermore, I would have to hardcode that the kubecfg entry has to be deleted if it's certificates are null, or implement a function that checks if infodata should be removed depending on the current infodata implementation.

Copy link
Contributor

@swilen-iwanow swilen-iwanow left a comment

Choose a reason for hiding this comment

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

the leftover fields in ShootState are my only concern, otherwise LGTM

@rfranzke rfranzke merged commit 4863ff3 into gardener:master Aug 12, 2020
@gardener-robot gardener-robot added priority/3 Priority (lower number equals higher priority) needs/lgtm and removed priority/3 Priority (lower number equals higher priority) needs/review labels Mar 8, 2021
@plkokanov plkokanov deleted the cp-migration/infodata branch December 9, 2022 11:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/control-plane-migration Control plane migration related kind/enhancement Enhancement, improvement, extension
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants