Fix crash in merging http routes#56499
Merged
istio-testing merged 3 commits intoistio:masterfrom Jun 4, 2025
Merged
Conversation
Collaborator
|
Skipping CI for Draft Pull Request. |
Member
Author
|
/ok-to-test |
Collaborator
|
@howardjohn: The following test failed, say
DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here. |
Collaborator
|
In response to a cherrypick label: new pull request created: #56517 |
2 tasks
fjglira
pushed a commit
to fjglira/istio
that referenced
this pull request
Sep 26, 2025
* upstream/master: (28 commits) Automator: update common-files@master in istio/istio@master (istio#56545) Automator: update proxy@master in istio/istio@master (istio#56544) Automator: update go-control-plane in istio/istio@master (istio#56543) Automator: update proxy@master in istio/istio@master (istio#56540) Automator: update ztunnel@master in istio/istio@master (istio#56532) Ambient: In ambient index, filter configs by revision (istio#56477) Automator: update istio/client-go@master dependency in istio/istio@master (istio#56539) Automator: update proxy@master in istio/istio@master (istio#56538) Automator: update common-files@master in istio/istio@master (istio#56537) optimization: allow for lazy sidecar initialization (istio#47221) static collection eager indexes (istio#56530) fix typo in flag (istio#56534) feat: enable support for proxy protocol on status port (istio#55986) remove finding of pods by IP (istio#56502) Automator: update proxy@master in istio/istio@master (istio#56528) migrate file monitor to krt (istio#55970) Automator: update istio/client-go@master dependency in istio/istio@master (istio#56525) Automator: update ztunnel@master in istio/istio@master (istio#56518) Fix crash in merging http routes (istio#56499) krt: add assertions (istio#56510) ...
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.
Fixes #56456
The issue here is due to how the collection is setup, we can have 2 input keys mapping to 1 output key. This corrupts krt's internal state. In order to catch this, I added assertions to krt: #56510.
The reason this happens is the input key is the merge key, so the hostname. The output key is the first object with the hostname. So if the hostname changes from host1 to host2, both of these map to the same object. Depending on the exact order of event processing this can lead to corrupted state, missing items, etc.
The solution is to include the key in the output. The output is config.config which already has a key of 'namespace/name'. I attempted a clean way to add an additional key (#56510) but it fell apart. We could make the collection not a
config.configbut that is a pain. Instead, I opted to set the name to the merge key. I think this is better anyways, since it is kind of weird to use an arbitrary object as the name. The name doesn't really matter though.Note: we use the merge in other places but already do it safely.