Closed NeverMorewd closed 11 months ago
It seems that the cts from CreateLinkedTokenSource() need to be dispose manually.
I has apply the workaround with adding using
in front of var combined
in MessageReader.cs
public async Task<bool> MoveNext(CancellationToken cancellationToken)
{
try
{
using var combined =
CancellationTokenSource.CreateLinkedTokenSource(cancellationToken, _callCancellationToken,
_deadline.Token);
return await _payloadQueue.MoveNext(combined.Token).ConfigureAwait(false);
}
catch (OperationCanceledException)
{
if (_deadline.IsExpired)
{
throw new RpcException(new Status(StatusCode.DeadlineExceeded, ""));
}
else
{
throw new RpcException(Status.DefaultCancelled);
}
}
}
Thanks, #56 merged and included in 3.0.0.