Skip to content

Conversation

kuntal1461
Copy link
Contributor

Fixes #4618.

Summary

MCP-annotated beans were discovered/registered in a non-deterministic order,
causing flaky behavior in wiring and tests. This change enforces a stable,
deterministic ordering before registration.

Changes

  • Introduce a predictable ordering of MCP-annotated beans prior to registration
  • Add regression test: McpClientSpecOrderingReproTests
  • Minor refactor in McpClientSpecificationFactoryAutoConfiguration for clarity

How I tested

  • Ran mvn clean verify locally; tests pass
  • Verified stable order across multiple runs

Notes

  • No behavior change beyond ordering; existing APIs remain the same

Signed-off-by: Kuntal Maity kuntal.1461@gmail.com

@kuntal1461 kuntal1461 force-pushed the fix/mcp-annotated-beans-order-4618 branch from 3180eae to f5705e9 Compare October 14, 2025 16:29
…s#4618)

Signed-off-by: Kuntal Maity kuntal.1461@gmail.com

Signed-off-by: Kuntal Maity <kuntal.1461@gmail.com>
@kuntal1461 kuntal1461 force-pushed the fix/mcp-annotated-beans-order-4618 branch from f5705e9 to 42322e1 Compare October 14, 2025 16:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

MCPAnotated beans found in wrong order

2 participants