You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
refactor(server): simplify StdioServerTransport constructor and remove Configuration class
- Replaced the builder-based setup with a streamlined primary constructor for `StdioServerTransport`.
- Removed the `Configuration` class for reduced complexity and enhanced readability.
- Updated `StdioServerTransportTest` to reflect the refactored initialization.
- Refactor cleanup.
Copy file name to clipboardExpand all lines: kotlin-sdk-server/api/kotlin-sdk-server.api
+2-23Lines changed: 2 additions & 23 deletions
Original file line number
Diff line number
Diff line change
@@ -186,35 +186,14 @@ public final class io/modelcontextprotocol/kotlin/sdk/server/SseServerTransport
186
186
}
187
187
188
188
public final class io/modelcontextprotocol/kotlin/sdk/server/StdioServerTransport : io/modelcontextprotocol/kotlin/sdk/shared/AbstractTransport {
189
-
public fun <init> (Lkotlin/jvm/functions/Function1;)V
190
189
public fun <init> (Lkotlinx/io/Source;Lkotlinx/io/Sink;)V
190
+
public fun <init> (Lkotlinx/io/Source;Lkotlinx/io/Sink;JLkotlinx/coroutines/channels/Channel;Lkotlinx/coroutines/channels/Channel;Lkotlinx/coroutines/CoroutineDispatcher;Lkotlinx/coroutines/CoroutineDispatcher;Lkotlinx/coroutines/CoroutineDispatcher;Lkotlinx/coroutines/CoroutineScope;)V
191
+
public synthetic fun <init> (Lkotlinx/io/Source;Lkotlinx/io/Sink;JLkotlinx/coroutines/channels/Channel;Lkotlinx/coroutines/channels/Channel;Lkotlinx/coroutines/CoroutineDispatcher;Lkotlinx/coroutines/CoroutineDispatcher;Lkotlinx/coroutines/CoroutineDispatcher;Lkotlinx/coroutines/CoroutineScope;ILkotlin/jvm/internal/DefaultConstructorMarker;)V
191
192
public fun close (Lkotlin/coroutines/Continuation;)Ljava/lang/Object;
192
193
public fun send (Lio/modelcontextprotocol/kotlin/sdk/types/JSONRPCMessage;Lio/modelcontextprotocol/kotlin/sdk/shared/TransportSendOptions;Lkotlin/coroutines/Continuation;)Ljava/lang/Object;
193
194
public fun start (Lkotlin/coroutines/Continuation;)Ljava/lang/Object;
194
195
}
195
196
196
-
public final class io/modelcontextprotocol/kotlin/sdk/server/StdioServerTransport$Configuration {
197
-
public fun <init> ()V
198
-
public final fun getCoroutineScope ()Lkotlinx/coroutines/CoroutineScope;
199
-
public final fun getProcessingJobDispatcher ()Lkotlinx/coroutines/CoroutineDispatcher;
200
-
public final fun getReadBufferSize ()J
201
-
public final fun getReadChannelBufferSize ()I
202
-
public final fun getReadingJobDispatcher ()Lkotlinx/coroutines/CoroutineDispatcher;
203
-
public final fun getSink ()Lkotlinx/io/Sink;
204
-
public final fun getSource ()Lkotlinx/io/Source;
205
-
public final fun getWriteChannelBufferSize ()I
206
-
public final fun getWritingJobDispatcher ()Lkotlinx/coroutines/CoroutineDispatcher;
207
-
public final fun setCoroutineScope (Lkotlinx/coroutines/CoroutineScope;)V
208
-
public final fun setProcessingJobDispatcher (Lkotlinx/coroutines/CoroutineDispatcher;)V
209
-
public final fun setReadBufferSize (J)V
210
-
public final fun setReadChannelBufferSize (I)V
211
-
public final fun setReadingJobDispatcher (Lkotlinx/coroutines/CoroutineDispatcher;)V
212
-
public final fun setSink (Lkotlinx/io/Sink;)V
213
-
public final fun setSource (Lkotlinx/io/Source;)V
214
-
public final fun setWriteChannelBufferSize (I)V
215
-
public final fun setWritingJobDispatcher (Lkotlinx/coroutines/CoroutineDispatcher;)V
216
-
}
217
-
218
197
public final class io/modelcontextprotocol/kotlin/sdk/server/StreamableHttpServerTransport : io/modelcontextprotocol/kotlin/sdk/shared/AbstractTransport {
219
198
public static final field STANDALONE_SSE_STREAM_ID Ljava/lang/String;
Copy file name to clipboardExpand all lines: kotlin-sdk-server/src/jvmTest/kotlin/io/modelcontextprotocol/kotlin/sdk/server/StdioServerTransportTest.kt
0 commit comments