Ensure endpoint validation occurs before initial regeneration#11714
Merged
Ensure endpoint validation occurs before initial regeneration#11714
Conversation
0e82d79 to
a71b026
Compare
Contributor
Author
|
test-me-please |
aanm
approved these changes
May 27, 2020
Contributor
Author
|
restart-1.11 |
christarazi
reviewed
May 27, 2020
Member
christarazi
left a comment
There was a problem hiding this comment.
The code looks good to me, besides one question that I have.
a71b026 to
facb7a0
Compare
Contributor
Author
|
test-me-please |
facb7a0 to
22b8c5d
Compare
Contributor
Author
|
test-me-please |
1 similar comment
Contributor
Author
|
test-me-please |
Contributor
Author
|
test-me-please |
A following commit will require to wait on the K8sAPIGroupPodV1Core cache Signed-off-by: Thomas Graf <thomas@cilium.io>
Due to a performance optimization, validateEndpoint() was changed to use the pod store instad of contacting the apiserver directly. This required to make the validation async to wait until the pod cache is available. This change however caused the endpoint to be exposed and regenerated before the endpoint was fully validated. This in turn caused the validation to occur while the regeneration was being performed. When the validation then failed, the endpoint was deleted while the endpoint was being regenerated, causing the endpoint to fail with a "JoinEP" message in the logs. This commit requires the endpoint to be validated before exposure and initial regeneration. Fixes: #11645 Fixes: #11076 Fixes: #10856 Fixes: #10667 Fixes: #10278 Fixes: 9975bba ("pkg/endpoint: fetch pod and namespace labels from local stores") Signed-off-by: Thomas Graf <thomas@cilium.io>
22b8c5d to
8ff6f77
Compare
Contributor
Author
|
test-me-please |
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
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.
Due to a performance optimization, validateEndpoint() was changed to use
the pod store instad of contacting the apiserver directly. This required
to make the validation async to wait until the pod cache is available.
This change however caused the endpoint to be exposed and regenerated
before the endpoint was fully validated. This in turn caused the
validation to occur while the regeneration was being performed. When the
validation then failed, the endpoint was deleted while the endpoint was
being regenerated, causing the endpoint to fail with a "JoinEP" message
in the logs.
This commit requires the endpoint to be validated before exposure and
initial regeneration.
This problem only exists in master. No need to backport.
Fixes: #11645
Fixes: #11076
Fixes: #10856
Fixes: #10667
Fixes: #10278
Fixes: 9975bba ("pkg/endpoint: fetch pod and namespace labels from local stores")