Add ability for client to resume session (#1029)
This commit is contained in:
parent
979befdd14
commit
7f25ae9d2a
1 changed files with 433 additions and 3 deletions
|
|
@ -93,6 +93,11 @@ internal sealed partial class AutoDetectingClientSessionTransport : ITransport
|
|||
|
||||
private async Task InitializeSseTransportAsync(JsonRpcMessage message, CancellationToken cancellationToken)
|
||||
{
|
||||
if (_options.KnownSessionId is not null)
|
||||
{
|
||||
throw new InvalidOperationException("Streamable HTTP transport is required to resume an existing session.");
|
||||
}
|
||||
|
||||
var sseTransport = new SseClientSessionTransport(_name, _options, _httpClient, _messageChannel, _loggerFactory);
|
||||
|
||||
try
|
||||
|
|
|
|||
Loading…
Reference in a new issue