You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@dubbo.apache.org by "skrcode (via GitHub)" <gi...@apache.org> on 2026/08/27 20:01:26 UTC
[PR] fix(mcp): migrate to MCP SDK 0.18.3 JSON APIs [dubbo]
skrcode opened a new pull request, #16442:
URL: https://github.com/apache/dubbo/pull/16442
## What is the purpose of the change?
This companion PR completes the MCP SDK 0.18.3 upgrade in #16342. The SDK replaced its Jackson-specific APIs with `McpJsonMapper`/`TypeRef` and removed the deprecated string-schema `Tool` constructors, leaving the Dependabot head unable to compile.
The change:
- adapts Dubbo's existing `ObjectMapper` instances through the SDK-provided `JacksonMcpJsonMapper`;
- uses the SDK's new `TypeRef` transport contract;
- migrates tool creation to the mapper-aware builder, preserving the previous JSON Schema parsing behavior; and
- removes a redundant Mockito `@InjectMocks` path that constructed the SSE provider with a null mapper before the test's explicit setup.
No public API or MCP wire behavior is intentionally changed.
## Verification
- Reproduced 8 Java compilation errors on exact Dependabot head `09795dcd58e0137c63ea5307b025893cd1aa0c48` with `./mvnw -pl dubbo-plugin/dubbo-mcp -DskipTests compile`.
- `./mvnw -T 4 -pl dubbo-plugin/dubbo-mcp -am clean install -DskipTests -Dmaven.javadoc.skip=true` — all 53 reactor modules passed Checkstyle, Spotless, compilation, packaging, and installation.
- `./mvnw -pl dubbo-plugin/dubbo-mcp clean test verify -Pjacoco -DskipTests=false -DskipIntegrationTests=false -Dcheckstyle.skip=false -Dcheckstyle_unix.skip=false -Drat.skip=false -Dmaven.javadoc.skip=true` — 89 tests passed; JaCoCo report generated; zero Checkstyle violations; Spotless passed.
- `git diff --check` passed.
## Checklist
- [x] Make sure there is a [GitHub_issue](https://github.com/apache/dubbo/issues) field for the change. (Dependency-upgrade context: #16342.)
- [x] Write a pull request description that is detailed enough to understand what the pull request does, how, and why.
- [x] Write necessary unit-test to verify your logic correction. Existing transport and tool-schema tests exercise the migrated paths; the SDK-dependent fixture was updated.
- [x] Make sure GitHub Actions can pass. [Why the workflow is failing and how to fix it?](../CONTRIBUTING.md)
--
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: notifications-unsubscribe@dubbo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org
Re: [PR] fix(mcp): migrate to MCP SDK 0.18.3 JSON APIs [dubbo]
Posted by "codecov-commenter (via GitHub)" <gi...@apache.org>.
codecov-commenter commented on PR #16442:
URL: https://github.com/apache/dubbo/pull/16442#issuecomment-5444836411
## [Codecov](https://app.codecov.io/gh/apache/dubbo/pull/16442?dropdown=coverage&src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) Report
:x: Patch coverage is `0%` with `29 lines` in your changes missing coverage. Please review.
:warning: Please [upload](https://docs.codecov.com/docs/codecov-uploader) report for BASE (`dependabot/maven/io.modelcontextprotocol.sdk-mcp-0.18.3@09795dc`). [Learn more](https://docs.codecov.io/docs/error-reference?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#section-missing-base-commit) about missing BASE report.
| [Files with missing lines](https://app.codecov.io/gh/apache/dubbo/pull/16442?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | Patch % | Lines |
|---|---|---|
| [...transport/DubboMcpStreamableTransportProvider.java](https://app.codecov.io/gh/apache/dubbo/pull/16442?src=pr&el=tree&filepath=dubbo-plugin%2Fdubbo-mcp%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fdubbo%2Fmcp%2Ftransport%2FDubboMcpStreamableTransportProvider.java&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-ZHViYm8tcGx1Z2luL2R1YmJvLW1jcC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvZHViYm8vbWNwL3RyYW5zcG9ydC9EdWJib01jcFN0cmVhbWFibGVUcmFuc3BvcnRQcm92aWRlci5qYXZh) | 0.00% | [10 Missing :warning: ](https://app.codecov.io/gh/apache/dubbo/pull/16442?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) |
| [...bo/mcp/transport/DubboMcpSseTransportProvider.java](https://app.codecov.io/gh/apache/dubbo/pull/16442?src=pr&el=tree&filepath=dubbo-plugin%2Fdubbo-mcp%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fdubbo%2Fmcp%2Ftransport%2FDubboMcpSseTransportProvider.java&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-ZHViYm8tcGx1Z2luL2R1YmJvLW1jcC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvZHViYm8vbWNwL3RyYW5zcG9ydC9EdWJib01jcFNzZVRyYW5zcG9ydFByb3ZpZGVyLmphdmE=) | 0.00% | [7 Missing :warning: ](https://app.codecov.io/gh/apache/dubbo/pull/16442?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) |
| [...ache/dubbo/mcp/tool/DubboOpenApiToolConverter.java](https://app.codecov.io/gh/apache/dubbo/pull/16442?src=pr&el=tree&filepath=dubbo-plugin%2Fdubbo-mcp%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fdubbo%2Fmcp%2Ftool%2FDubboOpenApiToolConverter.java&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-ZHViYm8tcGx1Z2luL2R1YmJvLW1jcC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvZHViYm8vbWNwL3Rvb2wvRHViYm9PcGVuQXBpVG9vbENvbnZlcnRlci5qYXZh) | 0.00% | [6 Missing :warning: ](https://app.codecov.io/gh/apache/dubbo/pull/16442?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) |
| [...pache/dubbo/mcp/tool/DubboServiceToolRegistry.java](https://app.codecov.io/gh/apache/dubbo/pull/16442?src=pr&el=tree&filepath=dubbo-plugin%2Fdubbo-mcp%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fdubbo%2Fmcp%2Ftool%2FDubboServiceToolRegistry.java&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#diff-ZHViYm8tcGx1Z2luL2R1YmJvLW1jcC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvZHViYm8vbWNwL3Rvb2wvRHViYm9TZXJ2aWNlVG9vbFJlZ2lzdHJ5LmphdmE=) | 0.00% | [6 Missing :warning: ](https://app.codecov.io/gh/apache/dubbo/pull/16442?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) |
<details><summary>Additional details and impacted files</summary>
```diff
@@ Coverage Diff @@
## dependabot/maven/io.modelcontextprotocol.sdk-mcp-0.18.3 #16442 +/- ##
==========================================================================================
Coverage ? 32.20%
Complexity ? 10213
==========================================================================================
Files ? 1952
Lines ? 89197
Branches ? 13374
==========================================================================================
Hits ? 28727
Misses ? 56229
Partials ? 4241
```
| [Flag](https://app.codecov.io/gh/apache/dubbo/pull/16442/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | Coverage Δ | |
|---|---|---|
| [samples-tests-java21](https://app.codecov.io/gh/apache/dubbo/pull/16442/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `32.20% <0.00%> (?)` | |
Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache#carryforward-flags-in-the-pull-request-comment) to find out more.
</details>
[:umbrella: View full report in Codecov by Harness](https://app.codecov.io/gh/apache/dubbo/pull/16442?dropdown=coverage&src=pr&el=continue&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache).
:loudspeaker: Have feedback on the report? [Share it here](https://about.codecov.io/codecov-pr-comment-feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache).
<details><summary> :rocket: New features to boost your workflow: </summary>
- :snowflake: [Test Analytics](https://docs.codecov.com/docs/test-analytics): Detect flaky tests, report on failures, and find test suite problems.
- :package: [JS Bundle Analysis](https://docs.codecov.com/docs/javascript-bundle-analysis): Save yourself from yourself by tracking and limiting bundle sizes in JS merges.
</details>
--
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: notifications-unsubscribe@dubbo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org
Re: [PR] fix(mcp): migrate to MCP SDK 0.18.3 JSON APIs [dubbo]
Posted by "skrcode (via GitHub)" <gi...@apache.org>.
skrcode closed pull request #16442: fix(mcp): migrate to MCP SDK 0.18.3 JSON APIs
URL: https://github.com/apache/dubbo/pull/16442
--
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: notifications-unsubscribe@dubbo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@dubbo.apache.org
For additional commands, e-mail: notifications-help@dubbo.apache.org