public StreamingSession(RequestHandler receiver, TransportHandler sender, ILogger logger, CancellationToken connectionCancellationToken = default) { _receiver = receiver ?? throw new ArgumentNullException(nameof(receiver)); _sender = sender ?? throw new ArgumentNullException(nameof(sender)); _sender.Subscribe(new ProtocolDispatcher(this)); _logger = logger ?? NullLogger.Instance; _connectionCancellationToken = connectionCancellationToken; }