Croway opened a new pull request, #2131: URL: https://github.com/apache/camel-spring-boot/pull/2131
## Summary Follow-up to apache/camel#30801 for CAMEL-26360. Camel's MCP bridge can now stamp the caller identity on resource, resource template and prompt exchanges, the same way it does for tools. The Spring Boot engines still called the resource and prompt handlers without a caller, so those routes saw no identity, even on an authenticated request. - `SpringAiMcpServerEngine` (SSE, STREAMABLE, STATELESS) and `SpringAiModernMcpServerEngine` (MODERN) now pass `SpringAiMcpTransportContext.from(...)` of the request to every resource, resource template and prompt handler, as they already do for tools. - With Camel's HTTP transport, these routes now receive `CamelMcpSecurityPrincipal`, `CamelAiToolSecurityPrincipalName`, `CamelAiToolSecurityPrincipalRoles` and, for an OAuth bearer token, the `CamelMcpOAuth*` properties. An anonymous request, or a transport without Camel's extractor, still sets nothing. - `usage.adoc` names these properties in the resource and prompt sections, and the docs page is regenerated. ## Tests - `SpringBootMcpServerTest` (STREAMABLE), `SpringBootMcpServerStatelessTest` and `SpringBootMcpServerModernTest` each add a fixed resource, a resource template and a prompt that return the caller, and check that a basic-auth caller reaches all three. Without the engine change, the three new tests fail with `name=null`. - `camel-mcp-server-starter`: 109 tests, 0 failures. CI needs a Camel 4.24.0-SNAPSHOT that includes apache/camel#30801. The snapshot on repository.apache.org is from 25 Nov, before the merge, so the build will only compile after the next snapshot deploy. _Claude Code on behalf of Federico Mariani_ -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
