loadbalancer: Fixes to test flakes#41085
Merged
joamaki merged 5 commits intocilium:mainfrom Aug 13, 2025
Merged
Conversation
Contributor
Author
|
Marked for v1.18 backport to proactively fix potential flakes there. The only production code changes was the added |
Contributor
Author
|
/test |
Wait for the prune to actually happen in the lb/prune command to make tests that e.g. do BPF state restoration more reliable as then we won't have a prune racing in the background. Update migrate-any-proto.txtar to call lb/prune before restoration to avoid a race. Signed-off-by: Jussi Maki <jussi@isovalent.com>
While the StateDB reconciler never calls the Update/Delete/Prune concurrently, we do want to be able to do BPFOps.ResetAndRestore from a test script to clear out the state. Since [sync.Mutex.Lock] is very cheap on an unlocked mutex, add a mutex around the BPFOps state so that we can inspect and manipulate it safely from tests and avoid very odd failures. Signed-off-by: Jussi Maki <jussi@isovalent.com>
This had changed when client-go was updated and this was causing false positive goroutine leak failures. Signed-off-by: Jussi Maki <jussi@isovalent.com>
The backends table wasn't checked after service and endpoint slice removal leading to sometimes adding the endpoints back before the deletions were processed leading to re-use of old IDs. Signed-off-by: Jussi Maki <jussi@isovalent.com>
e7b700e to
e51ef66
Compare
This should have never moved into 'Cell' as the whole point was to keep the legacy metrics and global variables out of 'Cell' so tests can use it. Fixes: 0b3672f ("pkg/metrics: prepare *metrics.Registry for use by operator.") Signed-off-by: Jussi Maki <jussi@isovalent.com>
Contributor
Author
|
/test |
Contributor
Author
|
/test |
brb
approved these changes
Aug 12, 2025
Contributor
Author
|
@tommyp1ckles could you please review the metrics-related commit as that reverts the move of |
tommyp1ckles
approved these changes
Aug 12, 2025
This was referenced Aug 13, 2025
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.
test/bpfops-resettest/bpfops-resetandtest/bpfops-summarydon't race with operationsmetrics.Celland move theNewLegacyMetricsback intometrics.AgentCell. This fixes test failure when run with-race.