Skip to content

Conversation

@scottslewis
Copy link

mcp-core so that mcp-json API is no longer needed and mcp-core has fewer dependencies.

See issue #612 and previous pr #682

Motivation and Context

Simplifies dependency structure, and reenables ability to use OSGi runtimes #562

How Has This Been Tested?

Have tested in OSGi environments running OSGi application.

Breaking Changes

This eliminates the need to deploy mcp-json jar, meaning that users will only have to (minimally) deploy mcp-core and either mcp-json-jackson2 or mcp-json-jackson3

Types of changes

  • [X ] Bug fix (non-breaking change which fixes an issue)

Checklist

  • [X ] I have read the MCP Documentation
  • [X ] My code follows the repository's style guidelines
  • New and existing tests pass locally
  • [X ] I have added appropriate error handling
  • [X ] I have added or updated documentation as needed

Additional context

To deal with the testing dependencies issues as described here: #682 (comment)

it may be necessary to add further changes/refactoring/moving of the test code (in mcp-core specifically). I'm willing to do or contribute to this refactoring if needed, once consensus is achieved.

…n API back into

mcp-core so that mcp-json API is no longer needed and mcp-core has fewer
dependencies.
@scottslewis scottslewis changed the title Rebasing on main after #742 merged. Moves mcp-json API back into mcp-core for simplified dependency and support of osgi runtimes Moves mcp-json API back into mcp-core for simplified dependency and support of osgi runtimes Jan 29, 2026
scottslewis and others added 4 commits January 29, 2026 13:43
…Loader.java

Co-authored-by: Luca Chang <131398524+LucaButBoring@users.noreply.github.com>
and DefaultMcpJsonSchemaSupplier as they were originally committed
accidently.  Thanks to LucaButBoring for pointing out the error.
@filiphr
Copy link
Contributor

filiphr commented Jan 30, 2026

@scottslewis, I'm not familiar with OSGi that much, but I have some general questions about the PR.

  • Why not delete mcp-json in this PR as well?
  • What is the difference between the mechanism that was being used before in the McpJsonInternal vs the one in this PR with the McpJsonDefaults? Of course taking into consideration the fact the move into mcp-core

@scottslewis
Copy link
Author

scottslewis commented Jan 30, 2026

@scottslewis, I'm not familiar with OSGi that much, but I have some general questions about the PR.

  • Why not delete mcp-json in this PR as well?

I could have...but chose to leave it so that the pr was not as large. If doing it in one step is preferable then that can be done.

  • What is the difference between the mechanism that was being used before in the McpJsonInternal vs the one in this PR with the McpJsonDefaults? Of course taking into consideration the fact the move into mcp-core

The impl of McpJsonDefaults is key to working (for json defaults) in non osgi and osgi environments. In non osgi environments, the serviceloader is used to find and load jackson2 or jackson3 impl for defaults as done previously.

In osgi, the serviceloader does not work the same...because of classloader-per-bundle as per osgi issue #562. In osgi, mcpjsondefaults is created and configured on start by the osgi sevice registry using scr metadata in manifests.

@scottslewis scottslewis changed the title Moves mcp-json API back into mcp-core for simplified dependency and support of osgi runtimes Moves mcp-json API back into mcp-core for simplified dependencies and support of osgi runtimes Jan 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants