diff --git a/mcp-bom/pom.xml b/mcp-bom/pom.xml index 3b2ad42..92bcdf3 100644 --- a/mcp-bom/pom.xml +++ b/mcp-bom/pom.xml @@ -7,7 +7,7 @@ io.modelcontextprotocol.sdk mcp-parent - 0.8.0-SNAPSHOT + 0.8.1 mcp-bom diff --git a/mcp-spring/mcp-spring-webflux/pom.xml b/mcp-spring/mcp-spring-webflux/pom.xml index 4d9f96e..9353750 100644 --- a/mcp-spring/mcp-spring-webflux/pom.xml +++ b/mcp-spring/mcp-spring-webflux/pom.xml @@ -6,7 +6,7 @@ io.modelcontextprotocol.sdk mcp-parent - 0.8.0-SNAPSHOT + 0.8.1 ../../pom.xml mcp-spring-webflux @@ -25,13 +25,13 @@ io.modelcontextprotocol.sdk mcp - 0.8.0-SNAPSHOT + 0.8.1 io.modelcontextprotocol.sdk mcp-test - 0.8.0-SNAPSHOT + 0.8.1 test diff --git a/mcp-spring/mcp-spring-webmvc/pom.xml b/mcp-spring/mcp-spring-webmvc/pom.xml index 0eebdd2..c0badab 100644 --- a/mcp-spring/mcp-spring-webmvc/pom.xml +++ b/mcp-spring/mcp-spring-webmvc/pom.xml @@ -6,7 +6,7 @@ io.modelcontextprotocol.sdk mcp-parent - 0.8.0-SNAPSHOT + 0.8.1 ../../pom.xml mcp-spring-webmvc @@ -25,13 +25,13 @@ io.modelcontextprotocol.sdk mcp - 0.8.0-SNAPSHOT + 0.8.1 io.modelcontextprotocol.sdk mcp-test - 0.8.0-SNAPSHOT + 0.8.1 test diff --git a/mcp-test/pom.xml b/mcp-test/pom.xml index 717f031..f9b7f00 100644 --- a/mcp-test/pom.xml +++ b/mcp-test/pom.xml @@ -6,7 +6,7 @@ io.modelcontextprotocol.sdk mcp-parent - 0.8.0-SNAPSHOT + 0.8.1 mcp-test jar @@ -24,7 +24,7 @@ io.modelcontextprotocol.sdk mcp - 0.8.0-SNAPSHOT + 0.8.1 diff --git a/mcp/pom.xml b/mcp/pom.xml index 2170ffe..7ffc8d1 100644 --- a/mcp/pom.xml +++ b/mcp/pom.xml @@ -6,7 +6,7 @@ io.modelcontextprotocol.sdk mcp-parent - 0.8.0-SNAPSHOT + 0.8.1 mcp jar diff --git a/mcp/src/main/java/io/modelcontextprotocol/server/transport/StdioServerTransportProvider.java b/mcp/src/main/java/io/modelcontextprotocol/server/transport/StdioServerTransportProvider.java index 6a7d290..a8b980e 100644 --- a/mcp/src/main/java/io/modelcontextprotocol/server/transport/StdioServerTransportProvider.java +++ b/mcp/src/main/java/io/modelcontextprotocol/server/transport/StdioServerTransportProvider.java @@ -93,7 +93,9 @@ public class StdioServerTransportProvider implements McpServerTransportProvider @Override public void setSessionFactory(McpServerSession.Factory sessionFactory) { // Create a single session for the stdio connection - this.session = sessionFactory.create(new StdioMcpSessionTransport()); + var transport = new StdioMcpSessionTransport(); + this.session = sessionFactory.create(transport); + transport.initProcessing(); } @Override @@ -142,10 +144,6 @@ public class StdioServerTransportProvider implements McpServerTransportProvider "stdio-inbound"); this.outboundScheduler = Schedulers.fromExecutorService(Executors.newSingleThreadExecutor(), "stdio-outbound"); - - handleIncomingMessages(); - startInboundProcessing(); - startOutboundProcessing(); } @Override @@ -181,6 +179,12 @@ public class StdioServerTransportProvider implements McpServerTransportProvider logger.debug("Session transport closed"); } + private void initProcessing() { + handleIncomingMessages(); + startInboundProcessing(); + startOutboundProcessing(); + } + private void handleIncomingMessages() { this.inboundSink.asFlux().flatMap(message -> session.handle(message)).doOnTerminate(() -> { // The outbound processing will dispose its scheduler upon completion diff --git a/pom.xml b/pom.xml index 3c8f497..5f52bbc 100644 --- a/pom.xml +++ b/pom.xml @@ -6,7 +6,7 @@ io.modelcontextprotocol.sdk mcp-parent - 0.8.0-SNAPSHOT + 0.8.1 pom https://github.com/modelcontextprotocol/java-sdk Internal server error - Forgejo: Beyond coding. We Forge. 500 Internal server error Forgejo version: 17.0.0-dev-603-6cb6155db7+gitea-1.22.0
Internal server error
Forgejo version: 17.0.0-dev-603-6cb6155db7+gitea-1.22.0