50 instantiations of KestrelServerLimits
InMemory.FunctionalTests (4)
Http3\Http3ConnectionTests.cs (1)
371var defaultLimits = new KestrelServerLimits();
MaxRequestBodySizeTests.cs (3)
294Assert.Equal(new KestrelServerLimits().MaxRequestBodySize, feature.MaxRequestBodySize); 334Assert.Equal(new KestrelServerLimits().MaxRequestBodySize, feature.MaxRequestBodySize); 391"Content-Length: " + (new KestrelServerLimits().MaxRequestBodySize + 1),
Microsoft.AspNetCore.Server.Kestrel.Core (1)
KestrelServerOptions.cs (1)
183public KestrelServerLimits Limits { get; } = new KestrelServerLimits();
Microsoft.AspNetCore.Server.Kestrel.Core.Tests (45)
Http3\Http3FrameWriterTests.cs (1)
58var kestrelLimits = new KestrelServerLimits();
KestrelServerLimitsTests.cs (44)
15Assert.Equal(64 * 1024, (new KestrelServerLimits()).MaxResponseBufferSize); 25(new KestrelServerLimits()).MaxResponseBufferSize = value; 36var o = new KestrelServerLimits(); 44Assert.Equal(1024 * 1024, (new KestrelServerLimits()).MaxRequestBufferSize); 54(new KestrelServerLimits()).MaxRequestBufferSize = value; 63var o = new KestrelServerLimits(); 71Assert.Equal(8 * 1024, (new KestrelServerLimits()).MaxRequestLineSize); 82(new KestrelServerLimits()).MaxRequestLineSize = value; 91var o = new KestrelServerLimits(); 99Assert.Equal(32 * 1024, (new KestrelServerLimits()).MaxRequestHeadersTotalSize); 108var ex = Assert.Throws<ArgumentOutOfRangeException>(() => new KestrelServerLimits().MaxRequestHeadersTotalSize = value); 117var o = new KestrelServerLimits(); 125Assert.Equal(100, (new KestrelServerLimits()).MaxRequestHeaderCount); 136(new KestrelServerLimits()).MaxRequestHeaderCount = value; 145var o = new KestrelServerLimits(); 153Assert.Equal(TimeSpan.FromSeconds(130), new KestrelServerLimits().KeepAliveTimeout); 160Assert.Equal(value, new KestrelServerLimits { KeepAliveTimeout = value }.KeepAliveTimeout); 166Assert.Equal(TimeSpan.MaxValue, new KestrelServerLimits { KeepAliveTimeout = Timeout.InfiniteTimeSpan }.KeepAliveTimeout); 173var exception = Assert.Throws<ArgumentOutOfRangeException>(() => new KestrelServerLimits { KeepAliveTimeout = value }); 182Assert.Equal(TimeSpan.FromSeconds(30), new KestrelServerLimits().RequestHeadersTimeout); 189Assert.Equal(value, new KestrelServerLimits { RequestHeadersTimeout = value }.RequestHeadersTimeout); 195Assert.Equal(TimeSpan.MaxValue, new KestrelServerLimits { RequestHeadersTimeout = Timeout.InfiniteTimeSpan }.RequestHeadersTimeout); 202var exception = Assert.Throws<ArgumentOutOfRangeException>(() => new KestrelServerLimits { RequestHeadersTimeout = value }); 211Assert.Null(new KestrelServerLimits().MaxConcurrentConnections); 212Assert.Null(new KestrelServerLimits().MaxConcurrentUpgradedConnections); 221var limits = new KestrelServerLimits 235var ex = Assert.Throws<ArgumentOutOfRangeException>(() => new KestrelServerLimits().MaxConcurrentConnections = value); 246var limits = new KestrelServerLimits 259var ex = Assert.Throws<ArgumentOutOfRangeException>(() => new KestrelServerLimits().MaxConcurrentUpgradedConnections = value); 267Assert.Equal(30000000, new KestrelServerLimits().MaxRequestBodySize); 277var limits = new KestrelServerLimits 290var ex = Assert.Throws<ArgumentOutOfRangeException>(() => new KestrelServerLimits().MaxRequestBodySize = value); 297Assert.NotNull(new KestrelServerLimits().MinRequestBodyDataRate); 298Assert.Equal(240, new KestrelServerLimits().MinRequestBodyDataRate.BytesPerSecond); 299Assert.Equal(TimeSpan.FromSeconds(5), new KestrelServerLimits().MinRequestBodyDataRate.GracePeriod); 305Assert.NotNull(new KestrelServerLimits().MinResponseDataRate); 306Assert.Equal(240, new KestrelServerLimits().MinResponseDataRate.BytesPerSecond); 307Assert.Equal(TimeSpan.FromSeconds(5), new KestrelServerLimits().MinResponseDataRate.GracePeriod); 313Assert.Equal(1 << 14, new KestrelServerLimits().Http2.MaxFrameSize); 322var ex = Assert.Throws<ArgumentOutOfRangeException>(() => new KestrelServerLimits().Http2.MaxFrameSize = value); 329Assert.Equal(4096, new KestrelServerLimits().Http2.HeaderTableSize); 337var ex = Assert.Throws<ArgumentOutOfRangeException>(() => new KestrelServerLimits().Http2.HeaderTableSize = value); 344Assert.Equal(32 * 1024, new KestrelServerLimits().Http2.MaxRequestHeaderFieldSize); 353var ex = Assert.Throws<ArgumentOutOfRangeException>(() => new KestrelServerLimits().Http2.MaxRequestHeaderFieldSize = value);
25 references to KestrelServerLimits
InMemory.FunctionalTests (1)
Http3\Http3ConnectionTests.cs (1)
371var defaultLimits = new KestrelServerLimits();
Microsoft.AspNetCore.Server.Kestrel.Core (15)
Features\IDecrementConcurrentConnectionCountFeature.cs (2)
7/// A connection feature allowing middleware to stop counting connections towards <see cref="KestrelServerLimits.MaxConcurrentConnections"/>. 13/// Idempotent method to stop counting a connection towards <see cref="KestrelServerLimits.MaxConcurrentConnections"/>.
Features\IHttpMinRequestBodyDataRateFeature.cs (2)
9/// Instead, use <see cref="KestrelServerLimits.MinRequestBodyDataRate"/> for server-wide configuration which applies to both HTTP/2 and HTTP/1.x. 18/// Instead, use <see cref="KestrelServerLimits.MinRequestBodyDataRate"/> for server-wide configuration which applies to both HTTP/2 and HTTP/1.x.
Features\IHttpMinResponseDataRateFeature.cs (2)
8/// This feature is not available for HTTP/2 requests. Instead, use <see cref="KestrelServerLimits.MinResponseDataRate"/> 17/// This feature is not available for HTTP/2 requests. Instead, use <see cref="KestrelServerLimits.MinResponseDataRate"/>
Internal\Http2\Http2Connection.cs (2)
154var httpLimits = context.ServiceContext.ServerOptions.Limits; 215public KestrelServerLimits Limits => _context.ServiceContext.ServerOptions.Limits;
Internal\Http3\Http3Connection.cs (2)
62var httpLimits = context.ServiceContext.ServerOptions.Limits; 96public KestrelServerLimits Limits => _context.ServiceContext.ServerOptions.Limits;
Internal\Http3\Http3ControlStream.cs (1)
44var httpLimits = context.ServiceContext.ServerOptions.Limits;
Internal\Http3\Http3Stream.cs (1)
74public KestrelServerLimits Limits => _context.ServiceContext.ServerOptions.Limits;
Internal\Http3\IHttp3Stream.cs (2)
19/// Value is driven by <see cref="KestrelServerLimits.RequestHeadersTimeout"/>. 21/// Value is driven by <see cref="KestrelServerLimits.MinResponseDataRate"/>.
KestrelServerOptions.cs (1)
183public KestrelServerLimits Limits { get; } = new KestrelServerLimits();
Microsoft.AspNetCore.Server.Kestrel.Core.Tests (9)
Http3\Http3FrameWriterTests.cs (1)
58var kestrelLimits = new KestrelServerLimits();
KestrelServerLimitsTests.cs (8)
36var o = new KestrelServerLimits(); 63var o = new KestrelServerLimits(); 91var o = new KestrelServerLimits(); 117var o = new KestrelServerLimits(); 145var o = new KestrelServerLimits(); 221var limits = new KestrelServerLimits 246var limits = new KestrelServerLimits 277var limits = new KestrelServerLimits