Repository navigation
Conversation
A discovery sweep listed each connected server's tools one after another, so one slow or large upstream delayed every other server's tools/list by up to its own timeout. The sweep now lists up to 8 servers at once (discoveryListConcurrency) and records the results in the same order and with the same logging as before. A server's concurrent tools/list calls were already coalesced into one request, and each capture carries its own sequence, so the order in which the lists finish does not affect how their results are applied.
poolski
marked this pull request as ready for review
November 2, 2026 09:36
This branch has not been deployed
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.
A discovery sweep listed each connected server's tools one after another, so one slow or large upstream delayed every other server's
tools/listby up to its own timeout.The sweep now lists up to 8 servers at once (
discoveryListConcurrency). Results are recorded in the original order with the same logging,markSweptand capture handling. A server's concurrenttools/listcalls were already coalesced into one request, and each capture carries its own process-global sequence, so the order in which lists finish does not change how their results are applied.TestDiscoverToolsListsServersConcurrentlyuses three upstreams whosetools/listwaits for another list to be in flight and requires the sweep to overlap them.Testing
go test -race ./internal/upstream/...scripts/test-api-e2e.sh(70/70)golangci-lintwith.github/.golangci.yml, bare and--build-tags server: no new issues