53 instantiations of MinDataRate
InMemory.FunctionalTests (23)
Http2\Http2TimeoutTests.cs (11)
353limits.MinResponseDataRate = new MinDataRate(480, TimeSpan.FromSeconds(2.5)); 406limits.MinResponseDataRate = new MinDataRate(480, TimeSpan.FromSeconds(2.5)); 461limits.MinResponseDataRate = new MinDataRate(480, TimeSpan.FromSeconds(2.5)); 513limits.MinResponseDataRate = new MinDataRate(480, TimeSpan.FromSeconds(2.5)); 567limits.MinResponseDataRate = new MinDataRate(480, TimeSpan.FromSeconds(2.5)); 633limits.MinRequestBodyDataRate = new MinDataRate(480, TimeSpan.FromSeconds(2.5)); 680limits.MinRequestBodyDataRate = new MinDataRate(480, TimeSpan.FromSeconds(2.5)); 731limits.MinRequestBodyDataRate = new MinDataRate(480, TimeSpan.FromSeconds(2.5)); 798limits.MinRequestBodyDataRate = new MinDataRate(480, TimeSpan.FromSeconds(2.5)); 866limits.MinRequestBodyDataRate = new MinDataRate(480, TimeSpan.FromSeconds(2.5)); 923limits.MinRequestBodyDataRate = new MinDataRate(480, TimeSpan.FromSeconds(2.5));
Http2\Http2WebSocketTests.cs (1)
328limits.MinRequestBodyDataRate = new MinDataRate(480, TimeSpan.FromSeconds(2.5));
Http3\Http3TimeoutTests.cs (8)
341limits.MinRequestBodyDataRate = new MinDataRate(480, TimeSpan.FromSeconds(2.5)); 383limits.MinResponseDataRate = new MinDataRate(480, TimeSpan.FromSeconds(2.5)); 451limits.MinResponseDataRate = new MinDataRate(480, TimeSpan.FromSeconds(2.5)); 493limits.MinResponseDataRate = new MinDataRate(480, TimeSpan.FromSeconds(2.5)); 535limits.MinRequestBodyDataRate = new MinDataRate(480, TimeSpan.FromSeconds(2.5)); 581limits.MinRequestBodyDataRate = new MinDataRate(480, TimeSpan.FromSeconds(2.5)); 636limits.MinRequestBodyDataRate = new MinDataRate(480, TimeSpan.FromSeconds(2.5)); 692limits.MinRequestBodyDataRate = new MinDataRate(480, TimeSpan.FromSeconds(2.5));
RequestBodyTimeoutTests.cs (2)
33new MinDataRate(bytesPerSecond: 1, gracePeriod: gracePeriod); 164new MinDataRate(bytesPerSecond: 1, gracePeriod: gracePeriod);
ResponseDrainingTests.cs (1)
26var minRate = new MinDataRate(16384, TimeSpan.FromSeconds(2));
Microsoft.AspNetCore.Server.Kestrel.Core (2)
KestrelServerLimits.cs (2)
360new MinDataRate(bytesPerSecond: 240, gracePeriod: TimeSpan.FromSeconds(5)); 384new MinDataRate(bytesPerSecond: 240, gracePeriod: TimeSpan.FromSeconds(5));
Microsoft.AspNetCore.Server.Kestrel.Core.Tests (22)
Http1\Http1ConnectionTests.cs (3)
166_http1Connection.MinRequestBodyDataRate = new MinDataRate(bytesPerSecond: 1, gracePeriod: TimeSpan.MaxValue); 176_http1Connection.MinResponseDataRate = new MinDataRate(bytesPerSecond: 1, gracePeriod: TimeSpan.MaxValue); 1186new MinDataRate(bytesPerSecond: 1, gracePeriod: TimeSpan.MaxValue)
Http2\Http2HttpProtocolFeatureCollectionTests.cs (1)
55Assert.Throws<NotSupportedException>(() => minRateFeature.MinDataRate = new MinDataRate(1, TimeSpan.FromSeconds(2)));
Http3\Http3HttpProtocolFeatureCollectionTests.cs (1)
55Assert.Throws<NotSupportedException>(() => minRateFeature.MinDataRate = new MinDataRate(1, TimeSpan.FromSeconds(2)));
MinDataRateTests.cs (4)
17Assert.Equal(value, new MinDataRate(bytesPerSecond: value, gracePeriod: TimeSpan.MaxValue).BytesPerSecond); 26var exception = Assert.Throws<ArgumentOutOfRangeException>(() => new MinDataRate(bytesPerSecond: value, gracePeriod: TimeSpan.MaxValue)); 36Assert.Equal(value, new MinDataRate(bytesPerSecond: 1, gracePeriod: value).GracePeriod); 43var exception = Assert.Throws<ArgumentOutOfRangeException>(() => new MinDataRate(bytesPerSecond: 1, gracePeriod: value));
TimeoutControlTests.cs (13)
63var minRate = new MinDataRate(bytesPerSecond: 100, gracePeriod: TimeSpan.FromSeconds(2)); 95var minRate = new MinDataRate(bytesPerSecond: 100, gracePeriod: gracePeriod); 155var minRate = new MinDataRate(bytesPerSecond: 100, gracePeriod: TimeSpan.FromSeconds(2)); 211var minRate = new MinDataRate(bytesPerSecond: 100, gracePeriod: TimeSpan.FromSeconds(2)); 257var minRate = new MinDataRate(bytesPerSecond: 100, gracePeriod: TimeSpan.FromSeconds(2)); 286var minRate = new MinDataRate(bytesPerSecond: 100, gracePeriod: TimeSpan.FromSeconds(2)); 334var minRate = new MinDataRate(bytesPerSecond: 100, gracePeriod: TimeSpan.FromSeconds(2)); 373var minRate = new MinDataRate(bytesPerSecond: 100, gracePeriod: TimeSpan.FromSeconds(2)); 391var minRate = new MinDataRate(bytesPerSecond: 100, gracePeriod: TimeSpan.FromSeconds(5)); 415var minRate = new MinDataRate(bytesPerSecond: 100, gracePeriod: TimeSpan.FromSeconds(2)); 446var minRate = new MinDataRate(bytesPerSecond: 100, gracePeriod: TimeSpan.FromSeconds(5)); 479var minRate = new MinDataRate(bytesPerSecond: 100, gracePeriod: TimeSpan.FromSeconds(2)); 504var minRate = new MinDataRate(bytesPerSecond, gracePeriod);
Sockets.FunctionalTests (6)
src\Servers\Kestrel\test\FunctionalTests\ResponseTests.cs (6)
514MinResponseDataRate = new MinDataRate(bytesPerSecond: 1024 * 1024, gracePeriod: TimeSpan.FromSeconds(2)) 648MinResponseDataRate = new MinDataRate(bytesPerSecond: 1024 * 1024, gracePeriod: TimeSpan.FromSeconds(2)) 769MinResponseDataRate = new MinDataRate(bytesPerSecond: 1024 * 1024, gracePeriod: TimeSpan.FromSeconds(2)), 867MinResponseDataRate = new MinDataRate(bytesPerSecond: 240, gracePeriod: TimeSpan.FromSeconds(2)) 944MinResponseDataRate = new MinDataRate(bytesPerSecond: 240, gracePeriod: TimeSpan.FromSeconds(2)) 1031MinResponseDataRate = new MinDataRate(bytesPerSecond: 240, gracePeriod: TimeSpan.FromSeconds(2))
55 references to MinDataRate
InMemory.FunctionalTests (4)
Http2\Http2TestBase.cs (3)
1484public virtual void StartRequestBody(MinDataRate minRate) 1519public virtual void BytesWrittenToBuffer(MinDataRate minRate, long size) 1529public long GetResponseDrainDeadline(long ticks, MinDataRate minRate)
ResponseDrainingTests.cs (1)
26var minRate = new MinDataRate(16384, TimeSpan.FromSeconds(2));
Microsoft.AspNetCore.Server.Kestrel.Core (29)
Features\IHttpMinRequestBodyDataRateFeature.cs (1)
20MinDataRate? MinDataRate { get; set; }
Features\IHttpMinResponseDataRateFeature.cs (1)
20MinDataRate? MinDataRate { get; set; }
Internal\Http\Http1Connection.cs (1)
78public MinDataRate? MinResponseDataRate { get; set; }
Internal\Http\Http1Connection.FeatureCollection.cs (2)
19MinDataRate? IHttpMinRequestBodyDataRateFeature.MinDataRate 25MinDataRate? IHttpMinResponseDataRateFeature.MinDataRate
Internal\Http\HttpProtocol.cs (1)
117public MinDataRate? MinRequestBodyDataRate { get; set; }
Internal\Http2\Http2FrameWriter.cs (3)
83private readonly MinDataRate? _minResponseDataRate; 115MinDataRate? minResponseDataRate, 830static async ValueTask<FlushResult> FlushAsyncAwaited(ValueTask<FlushResult> writeTask, ITimeoutControl timeoutControl, MinDataRate? minResponseDataRate)
Internal\Http2\Http2Stream.FeatureCollection.cs (1)
48MinDataRate? IHttpMinRequestBodyDataRateFeature.MinDataRate
Internal\Http3\Http3Connection.cs (1)
307var minDataRate = _context.ServiceContext.ServerOptions.Limits.MinResponseDataRate;
Internal\Http3\Http3FrameWriter.cs (2)
37private readonly MinDataRate? _minResponseDataRate; 59public Http3FrameWriter(ConnectionContext connectionContext, ITimeoutControl timeoutControl, MinDataRate? minResponseDataRate, MemoryPool<byte> memoryPool, KestrelTrace log, IStreamIdFeature streamIdFeature, Http3PeerSettings clientPeerSettings, IHttp3Stream http3Stream)
Internal\Http3\Http3Stream.FeatureCollection.cs (1)
41MinDataRate? IHttpMinRequestBodyDataRateFeature.MinDataRate
Internal\Infrastructure\ITimeoutControl.cs (3)
19void StartRequestBody(MinDataRate minRate); 27void BytesWrittenToBuffer(MinDataRate minRate, long count); 28long GetResponseDrainDeadline(long timestamp, MinDataRate minRate);
Internal\Infrastructure\PipeWriterHelpers\TimingPipeFlusher.cs (3)
46public ValueTask<FlushResult> FlushAsync(MinDataRate? minRate, long count) 51public ValueTask<FlushResult> FlushAsync(MinDataRate? minRate, long count, IHttpOutputAborter? outputAborter, CancellationToken cancellationToken) 77private async ValueTask<FlushResult> TimeFlushAsyncAwaited(ValueTask<FlushResult> pipeFlushTask, MinDataRate? minRate, IHttpOutputAborter? outputAborter, CancellationToken cancellationToken)
Internal\Infrastructure\TimeoutControl.cs (4)
20private MinDataRate? _minReadRate; 200public void StartRequestBody(MinDataRate minRate) 284public void BytesWrittenToBuffer(MinDataRate minRate, long count) 336public long GetResponseDrainDeadline(long timestamp, MinDataRate minRate)
Internal\Infrastructure\TimeoutControlExtensions.cs (1)
8public static void StartDrainTimeout(this ITimeoutControl timeoutControl, MinDataRate? minDataRate, long? maxResponseBufferSize)
KestrelServerLimits.cs (2)
358public MinDataRate? MinRequestBodyDataRate { get; set; } = 382public MinDataRate? MinResponseDataRate { get; set; } =
MinDataRate.cs (2)
14/// Creates a new instance of <see cref="MinDataRate"/>. 41/// The amount of time to delay enforcement of <see cref="MinDataRate" />,
Microsoft.AspNetCore.Server.Kestrel.Core.Tests (19)
Http1\Http1ConnectionTests.cs (4)
330public void ConfiguringIHttpMinRequestBodyDataRateFeatureSetsMinRequestBodyDataRate(MinDataRate minDataRate) 339public void ConfiguringIHttpMinResponseDataRateFeatureSetsMinResponseDataRate(MinDataRate minDataRate) 1183public static TheoryData<MinDataRate> MinDataRateData => new TheoryData<MinDataRate>
MessageBodyTests.cs (2)
918var minReadRate = input.Http1Connection.MinRequestBodyDataRate; 947var minReadRate = input.Http1Connection.MinRequestBodyDataRate;
TimeoutControlTests.cs (13)
63var minRate = new MinDataRate(bytesPerSecond: 100, gracePeriod: TimeSpan.FromSeconds(2)); 95var minRate = new MinDataRate(bytesPerSecond: 100, gracePeriod: gracePeriod); 155var minRate = new MinDataRate(bytesPerSecond: 100, gracePeriod: TimeSpan.FromSeconds(2)); 211var minRate = new MinDataRate(bytesPerSecond: 100, gracePeriod: TimeSpan.FromSeconds(2)); 257var minRate = new MinDataRate(bytesPerSecond: 100, gracePeriod: TimeSpan.FromSeconds(2)); 286var minRate = new MinDataRate(bytesPerSecond: 100, gracePeriod: TimeSpan.FromSeconds(2)); 334var minRate = new MinDataRate(bytesPerSecond: 100, gracePeriod: TimeSpan.FromSeconds(2)); 373var minRate = new MinDataRate(bytesPerSecond: 100, gracePeriod: TimeSpan.FromSeconds(2)); 391var minRate = new MinDataRate(bytesPerSecond: 100, gracePeriod: TimeSpan.FromSeconds(5)); 415var minRate = new MinDataRate(bytesPerSecond: 100, gracePeriod: TimeSpan.FromSeconds(2)); 446var minRate = new MinDataRate(bytesPerSecond: 100, gracePeriod: TimeSpan.FromSeconds(5)); 479var minRate = new MinDataRate(bytesPerSecond: 100, gracePeriod: TimeSpan.FromSeconds(2)); 504var minRate = new MinDataRate(bytesPerSecond, gracePeriod);
Microsoft.AspNetCore.Server.Kestrel.Microbenchmarks (3)
Mocks\MockTimeoutControl.cs (3)
19public void BytesWrittenToBuffer(MinDataRate minRate, long count) 27public long GetResponseDrainDeadline(long ticks, MinDataRate minRate) 44public void StartRequestBody(MinDataRate minRate)