Fix duplicate calls in EndpointTopologyBuilder#13816
Merged
Conversation
…te in e2e EndpointTopologyBuilder.build() created a new Call for every CallDetail without deduplication, unlike ServiceTopologyBuilder which uses a HashMap. This caused duplicate call entries when storage returns multiple records for the same endpoint relation. Also switch all dependency topology e2e expected files from `contains` to `containsOnce` to enforce strict 1:1 matching and catch duplicates.
… files Upgrade skywalking-infra-e2e to include the noDuplicates pipe function. Add | noDuplicates to all dependency topology expected files for both nodes and calls, ensuring storage-level duplicates are caught in e2e.
wankai123
approved these changes
Apr 14, 2026
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.
Fix duplicate calls in endpoint topology query results
EndpointTopologyBuilder.build()created a newCallfor everyCallDetailwithout deduplication.Unlike
ServiceTopologyBuilderwhich uses aHashMap<String, Call>to deduplicate by relation ID,EndpointTopologyBuilderblindly added every record — causing duplicate call entries when storagereturns multiple records for the same endpoint relation.
The fix adds the same
HashMap<String, Call>dedup pattern. E2E expected files are also updatedfrom
containstocontainsOncewith| noDuplicatesfor topology nodes and calls to enforcestrict 1:1 matching and catch any duplicates. Infra-e2e bumped to
ef073adto include thenoDuplicatespipe function.CHANGESlog.