18 types derived from MemoryPool
InMemory.FunctionalTests (2)
src\Shared\Buffers.MemoryPool\DiagnosticMemoryPool.cs (1)
11internal sealed class DiagnosticMemoryPool : MemoryPool<byte>
src\Shared\Buffers.MemoryPool\PinnedBlockMemoryPool.cs (1)
13internal sealed class PinnedBlockMemoryPool : MemoryPool<byte>
Microsoft.AspNetCore.Server.HttpSys (2)
src\Shared\Buffers.MemoryPool\DiagnosticMemoryPool.cs (1)
11internal sealed class DiagnosticMemoryPool : MemoryPool<byte>
src\Shared\Buffers.MemoryPool\PinnedBlockMemoryPool.cs (1)
13internal sealed class PinnedBlockMemoryPool : MemoryPool<byte>
Microsoft.AspNetCore.Server.IIS (2)
src\Shared\Buffers.MemoryPool\DiagnosticMemoryPool.cs (1)
11internal sealed class DiagnosticMemoryPool : MemoryPool<byte>
src\Shared\Buffers.MemoryPool\PinnedBlockMemoryPool.cs (1)
13internal sealed class PinnedBlockMemoryPool : MemoryPool<byte>
Microsoft.AspNetCore.Server.Kestrel.Core.Tests (2)
src\Shared\Buffers.MemoryPool\DiagnosticMemoryPool.cs (1)
11internal sealed class DiagnosticMemoryPool : MemoryPool<byte>
src\Shared\Buffers.MemoryPool\PinnedBlockMemoryPool.cs (1)
13internal sealed class PinnedBlockMemoryPool : MemoryPool<byte>
Microsoft.AspNetCore.Server.Kestrel.Microbenchmarks (2)
src\Shared\Buffers.MemoryPool\DiagnosticMemoryPool.cs (1)
11internal sealed class DiagnosticMemoryPool : MemoryPool<byte>
src\Shared\Buffers.MemoryPool\PinnedBlockMemoryPool.cs (1)
13internal sealed class PinnedBlockMemoryPool : MemoryPool<byte>
Microsoft.AspNetCore.Server.Kestrel.Transport.NamedPipes (2)
src\Shared\Buffers.MemoryPool\DiagnosticMemoryPool.cs (1)
11internal sealed class DiagnosticMemoryPool : MemoryPool<byte>
src\Shared\Buffers.MemoryPool\PinnedBlockMemoryPool.cs (1)
13internal sealed class PinnedBlockMemoryPool : MemoryPool<byte>
Microsoft.AspNetCore.Server.Kestrel.Transport.Quic (2)
src\Shared\Buffers.MemoryPool\DiagnosticMemoryPool.cs (1)
11internal sealed class DiagnosticMemoryPool : MemoryPool<byte>
src\Shared\Buffers.MemoryPool\PinnedBlockMemoryPool.cs (1)
13internal sealed class PinnedBlockMemoryPool : MemoryPool<byte>
Microsoft.AspNetCore.Server.Kestrel.Transport.Sockets (2)
src\Shared\Buffers.MemoryPool\DiagnosticMemoryPool.cs (1)
11internal sealed class DiagnosticMemoryPool : MemoryPool<byte>
src\Shared\Buffers.MemoryPool\PinnedBlockMemoryPool.cs (1)
13internal sealed class PinnedBlockMemoryPool : MemoryPool<byte>
System.Memory (2)
System\Buffers\ArrayMemoryPool.ArrayMemoryPoolBuffer.cs (1)
6internal sealed partial class ArrayMemoryPool<T> : MemoryPool<T>
System\Buffers\ArrayMemoryPool.cs (1)
8internal sealed partial class ArrayMemoryPool<T> : MemoryPool<T>
258 references to MemoryPool
http2cat (3)
src\Shared\Http2cat\Http2CatHostedService.cs (1)
86var memoryPool = context.Features.Get<IMemoryPoolFeature>()?.MemoryPool;
src\Shared\ServerInfrastructure\MemoryPoolExtensions.cs (2)
18public static int GetMinimumSegmentSize(this MemoryPool<byte> pool) 28public static int GetMinimumAllocSize(this MemoryPool<byte> pool)
IIS.FunctionalTests (3)
src\Shared\Http2cat\Http2CatHostedService.cs (1)
86var memoryPool = context.Features.Get<IMemoryPoolFeature>()?.MemoryPool;
src\Shared\ServerInfrastructure\MemoryPoolExtensions.cs (2)
18public static int GetMinimumSegmentSize(this MemoryPool<byte> pool) 28public static int GetMinimumAllocSize(this MemoryPool<byte> pool)
IIS.LongTests (3)
src\Shared\Http2cat\Http2CatHostedService.cs (1)
86var memoryPool = context.Features.Get<IMemoryPoolFeature>()?.MemoryPool;
src\Shared\ServerInfrastructure\MemoryPoolExtensions.cs (2)
18public static int GetMinimumSegmentSize(this MemoryPool<byte> pool) 28public static int GetMinimumAllocSize(this MemoryPool<byte> pool)
IIS.NewHandler.FunctionalTests (3)
src\Shared\Http2cat\Http2CatHostedService.cs (1)
86var memoryPool = context.Features.Get<IMemoryPoolFeature>()?.MemoryPool;
src\Shared\ServerInfrastructure\MemoryPoolExtensions.cs (2)
18public static int GetMinimumSegmentSize(this MemoryPool<byte> pool) 28public static int GetMinimumAllocSize(this MemoryPool<byte> pool)
IIS.NewShim.FunctionalTests (3)
src\Shared\Http2cat\Http2CatHostedService.cs (1)
86var memoryPool = context.Features.Get<IMemoryPoolFeature>()?.MemoryPool;
src\Shared\ServerInfrastructure\MemoryPoolExtensions.cs (2)
18public static int GetMinimumSegmentSize(this MemoryPool<byte> pool) 28public static int GetMinimumAllocSize(this MemoryPool<byte> pool)
IIS.ShadowCopy.Tests (2)
src\Shared\ServerInfrastructure\MemoryPoolExtensions.cs (2)
18public static int GetMinimumSegmentSize(this MemoryPool<byte> pool) 28public static int GetMinimumAllocSize(this MemoryPool<byte> pool)
IISExpress.FunctionalTests (3)
src\Shared\Http2cat\Http2CatHostedService.cs (1)
86var memoryPool = context.Features.Get<IMemoryPoolFeature>()?.MemoryPool;
src\Shared\ServerInfrastructure\MemoryPoolExtensions.cs (2)
18public static int GetMinimumSegmentSize(this MemoryPool<byte> pool) 28public static int GetMinimumAllocSize(this MemoryPool<byte> pool)
InMemory.FunctionalTests (23)
Http2\Http2TestBase.cs (3)
115private readonly MemoryPool<byte> _memoryPool = PinnedBlockMemoryPoolFactory.Create(); 1406private static PipeOptions GetInputPipeOptions(ServiceContext serviceContext, MemoryPool<byte> memoryPool, PipeScheduler writerScheduler) => new PipeOptions 1417private static PipeOptions GetOutputPipeOptions(ServiceContext serviceContext, MemoryPool<byte> memoryPool, PipeScheduler readerScheduler) => new PipeOptions
src\Servers\Kestrel\shared\test\Http3\Http3InMemory.cs (3)
77internal readonly MemoryPool<byte> _memoryPool = PinnedBlockMemoryPoolFactory.Create(); 363public static PipeOptions GetInputPipeOptions(ServiceContext serviceContext, MemoryPool<byte> memoryPool, PipeScheduler writerScheduler) => new PipeOptions 374public static PipeOptions GetOutputPipeOptions(ServiceContext serviceContext, MemoryPool<byte> memoryPool, PipeScheduler readerScheduler) => new PipeOptions
src\Servers\Kestrel\shared\test\TestContextFactory.cs (7)
53MemoryPool<byte> memoryPool = null, 66memoryPool ?? MemoryPool<byte>.Shared, 80MemoryPool<byte> memoryPool = null, 141MemoryPool<byte> memoryPool = null, 161memoryPool: memoryPool ?? MemoryPool<byte>.Shared, 182MemoryPool<byte> memoryPool = null, 211memoryPool: memoryPool ?? MemoryPool<byte>.Shared,
src\Servers\Kestrel\shared\test\TestServiceContext.cs (1)
76public Func<MemoryPool<byte>> MemoryPoolFactory { get; set; } = System.Buffers.PinnedBlockMemoryPoolFactory.Create;
src\Servers\Kestrel\shared\TransportConnection.cs (1)
38public virtual MemoryPool<byte> MemoryPool { get; } = default!;
src\Servers\Kestrel\shared\TransportConnection.FeatureCollection.cs (1)
19MemoryPool<byte> IMemoryPoolFeature.MemoryPool => MemoryPool;
src\Shared\Buffers.MemoryPool\DiagnosticMemoryPool.cs (2)
13private readonly MemoryPool<byte> _pool; 34public DiagnosticMemoryPool(MemoryPool<byte> pool, bool allowLateReturn = false, bool rentTracking = false)
src\Shared\Buffers.MemoryPool\MemoryPoolFactory.cs (2)
8public static MemoryPool<byte> Create() 17public static MemoryPool<byte> CreatePinnedBlockMemoryPool()
TestTransport\InMemoryTransportConnection.cs (2)
24public InMemoryTransportConnection(MemoryPool<byte> memoryPool, ILogger logger, PipeScheduler scheduler = null) 47public override MemoryPool<byte> MemoryPool { get; }
TestTransport\TestServer.cs (1)
33private readonly MemoryPool<byte> _memoryPool;
Interop.FunctionalTests (1)
Http3\Http3RequestTests.cs (1)
1153public MemoryPool<byte> MemoryPool { get; set; }
Microsoft.AspNetCore.Components.Server (4)
BlazorPack\SequenceOfT.cs (4)
27private readonly MemoryPool<T> memoryPool; 48public Sequence(MemoryPool<T> memoryPool) 80/// The <see cref="MemoryPool{T}"/> in use may itself have a minimum array length as well, 302/// Gets the backing array, when using an <see cref="ArrayPool{T}"/> instead of a <see cref="MemoryPool{T}"/>.
Microsoft.AspNetCore.Connections.Abstractions (3)
Features\IMemoryPoolFeature.cs (3)
9/// The <see cref="MemoryPool{T}"/> used by the connection. 14/// Gets the <see cref="MemoryPool{T}"/> used by the connection. 16MemoryPool<byte> MemoryPool { get; }
Microsoft.AspNetCore.Server.HttpSys (7)
HttpSysListener.cs (1)
35internal MemoryPool<byte> MemoryPool { get; } = PinnedBlockMemoryPoolFactory.Create();
src\Shared\Buffers.MemoryPool\DiagnosticMemoryPool.cs (2)
13private readonly MemoryPool<byte> _pool; 34public DiagnosticMemoryPool(MemoryPool<byte> pool, bool allowLateReturn = false, bool rentTracking = false)
src\Shared\Buffers.MemoryPool\MemoryPoolFactory.cs (2)
8public static MemoryPool<byte> Create() 17public static MemoryPool<byte> CreatePinnedBlockMemoryPool()
src\Shared\HttpSys\RequestProcessing\NativeRequestContext.cs (2)
43internal NativeRequestContext(MemoryPool<byte> memoryPool, uint? bufferSize, ulong requestId, bool useLatin1) 63_backingBuffer = MemoryPool<byte>.Shared.Rent(newSize);
Microsoft.AspNetCore.Server.HttpSys.FunctionalTests (3)
src\Shared\Http2cat\Http2CatHostedService.cs (1)
86var memoryPool = context.Features.Get<IMemoryPoolFeature>()?.MemoryPool;
src\Shared\ServerInfrastructure\MemoryPoolExtensions.cs (2)
18public static int GetMinimumSegmentSize(this MemoryPool<byte> pool) 28public static int GetMinimumAllocSize(this MemoryPool<byte> pool)
Microsoft.AspNetCore.Server.HttpSys.Microbenchmarks (1)
RequestHeaderBenchmarks.cs (1)
56var nativeContext = new NativeRequestContext(MemoryPool<byte>.Shared, null, 0, false);
Microsoft.AspNetCore.Server.HttpSys.Tests (13)
RequestHeaderTests.cs (13)
22var nativeContext = new NativeRequestContext(MemoryPool<byte>.Shared, null, 0, false); 63var nativeContext = new NativeRequestContext(MemoryPool<byte>.Shared, null, 0, false); 104var nativeContext = new NativeRequestContext(MemoryPool<byte>.Shared, null, 0, false); 123var nativeContext = new NativeRequestContext(MemoryPool<byte>.Shared, null, 0, false); 142var nativeContext = new NativeRequestContext(MemoryPool<byte>.Shared, null, 0, false); 189var nativeContext = new NativeRequestContext(MemoryPool<byte>.Shared, null, 0, false); 211var nativeContext = new NativeRequestContext(MemoryPool<byte>.Shared, null, 0, false); 233var nativeContext = new NativeRequestContext(MemoryPool<byte>.Shared, null, 0, false); 254var nativeContext = new NativeRequestContext(MemoryPool<byte>.Shared, null, 0, false); 274var nativeContext = new NativeRequestContext(MemoryPool<byte>.Shared, null, 0, false); 296var nativeContext = new NativeRequestContext(MemoryPool<byte>.Shared, null, 0, false); 318var nativeContext = new NativeRequestContext(MemoryPool<byte>.Shared, null, 0, false); 339var nativeContext = new NativeRequestContext(MemoryPool<byte>.Shared, null, 0, false);
Microsoft.AspNetCore.Server.IIS (14)
Core\IISHttpContext.cs (2)
54private readonly MemoryPool<byte> _memoryPool; 76MemoryPool<byte> memoryPool,
Core\IISHttpContextOfT.cs (1)
18public IISHttpContextOfT(MemoryPool<byte> memoryPool, IHttpApplication<TContext> application, NativeSafeHandle pInProcessHandler, IISServerOptions options, IISHttpServer server, ILogger logger, bool useLatin1)
Core\IISHttpServer.cs (3)
24private readonly MemoryPool<byte> _memoryPool = new PinnedBlockMemoryPool(); 279private readonly MemoryPool<byte> _memoryPool; 285public IISContextFactory(MemoryPool<byte> memoryPool, IHttpApplication<T> application, IISServerOptions options, IISHttpServer server, ILogger logger)
src\Shared\Buffers.MemoryPool\DiagnosticMemoryPool.cs (2)
13private readonly MemoryPool<byte> _pool; 34public DiagnosticMemoryPool(MemoryPool<byte> pool, bool allowLateReturn = false, bool rentTracking = false)
src\Shared\Buffers.MemoryPool\MemoryPoolFactory.cs (2)
8public static MemoryPool<byte> Create() 17public static MemoryPool<byte> CreatePinnedBlockMemoryPool()
src\Shared\HttpSys\RequestProcessing\NativeRequestContext.cs (2)
43internal NativeRequestContext(MemoryPool<byte> memoryPool, uint? bufferSize, ulong requestId, bool useLatin1) 63_backingBuffer = MemoryPool<byte>.Shared.Rent(newSize);
src\Shared\ServerInfrastructure\MemoryPoolExtensions.cs (2)
18public static int GetMinimumSegmentSize(this MemoryPool<byte> pool) 28public static int GetMinimumAllocSize(this MemoryPool<byte> pool)
Microsoft.AspNetCore.Server.Kestrel.Core (27)
Internal\BaseHttpConnectionContext.cs (2)
21MemoryPool<byte> memoryPool, 44public MemoryPool<byte> MemoryPool { get; }
Internal\Http\Http1Connection.cs (1)
80public MemoryPool<byte> MemoryPool { get; }
Internal\Http\Http1OutputProducer.cs (4)
29private readonly MemoryPool<byte> _memoryPool; 75MemoryPool<byte> memoryPool, 760else if (sizeHint <= MemoryPool<byte>.Shared.MaxBufferSize) 764var owner = MemoryPool<byte>.Shared.Rent(sizeHint);
Internal\Http2\Http2FrameWriter.cs (1)
117MemoryPool<byte> memoryPool,
Internal\Http2\Http2OutputProducer.cs (2)
29private readonly MemoryPool<byte> _memoryPool; 765private static Pipe CreateDataPipe(MemoryPool<byte> pool, bool scheduleInline)
Internal\Http2\Http2StreamContext.cs (1)
22MemoryPool<byte> memoryPool,
Internal\Http3\Http3FrameWriter.cs (2)
38private readonly MemoryPool<byte> _memoryPool; 59public Http3FrameWriter(ConnectionContext connectionContext, ITimeoutControl timeoutControl, MinDataRate? minResponseDataRate, MemoryPool<byte> memoryPool, KestrelTrace log, IStreamIdFeature streamIdFeature, Http3PeerSettings clientPeerSettings, IHttp3Stream http3Stream)
Internal\Http3\Http3OutputProducer.cs (3)
22private readonly MemoryPool<byte> _memoryPool; 38MemoryPool<byte> pool, 477private static Pipe CreateDataPipe(MemoryPool<byte> pool)
Internal\Http3\Http3StreamContext.cs (1)
22MemoryPool<byte> memoryPool,
Internal\HttpConnectionContext.cs (1)
22MemoryPool<byte> memoryPool,
Internal\HttpMultiplexedConnectionContext.cs (1)
21MemoryPool<byte> memoryPool,
Internal\Infrastructure\PipeWriterHelpers\ConcurrentPipeWriter.cs (2)
26private readonly MemoryPool<byte> _pool; 53public ConcurrentPipeWriter(PipeWriter innerPipeWriter, MemoryPool<byte> pool, Lock sync)
Middleware\HttpConnectionMiddleware.cs (1)
43memoryPoolFeature?.MemoryPool ?? System.Buffers.MemoryPool<byte>.Shared,
Middleware\HttpMultiplexedConnectionMiddleware.cs (1)
42memoryPoolFeature?.MemoryPool ?? System.Buffers.MemoryPool<byte>.Shared,
Middleware\HttpsConnectionMiddleware.cs (2)
144context.Features.Get<IMemoryPoolFeature>()?.MemoryPool ?? MemoryPool<byte>.Shared); 419private SslDuplexPipe CreateSslDuplexPipe(IDuplexPipe transport, MemoryPool<byte> memoryPool)
src\Shared\ServerInfrastructure\MemoryPoolExtensions.cs (2)
18public static int GetMinimumSegmentSize(this MemoryPool<byte> pool) 28public static int GetMinimumAllocSize(this MemoryPool<byte> pool)
Microsoft.AspNetCore.Server.Kestrel.Core.Tests (45)
DiagnosticMemoryPoolTests.cs (14)
14protected override MemoryPool<byte> CreatePool() => new DiagnosticMemoryPool(new PinnedBlockMemoryPool()); 19var memoryPool = CreatePool(); 28var memoryPool = CreatePool(); 39var memoryPool = CreatePool(); 51var memoryPool = CreatePool(); 63var memoryPool = CreatePool(); 76var memoryPool = CreatePool(); 98var memoryPool = CreatePool(); 111var memoryPool = CreatePool(); 125var memoryPool = CreatePool(); 140var memoryPool = CreatePool(); 164var memoryPool = CreatePool(); 215private static void ExpectDisposeException(MemoryPool<byte> memoryPool) 221private static void ExpectDisposeAggregateException(MemoryPool<byte> memoryPool, params Exception[] inner)
Http1\Http1ConnectionTestsBase.cs (1)
25internal MemoryPool<byte> _pipelineFactory;
Http1\Http1OutputProducerTests.cs (2)
21private readonly MemoryPool<byte> _memoryPool; 254public TestHttpOutputProducer(Pipe pipe, string connectionId, ConnectionContext connectionContext, MemoryPool<byte> memoryPool, KestrelTrace log, ITimeoutControl timeoutControl, IHttpMinResponseDataRateFeature minResponseDataRateFeature, ConnectionMetricsContext metricsContext, IHttpOutputAborter outputAborter)
Http2\Http2FrameWriterTests.cs (2)
14private readonly MemoryPool<byte> _dirtyMemoryPool; 29var dirtyMemoryPool = new Mock<MemoryPool<byte>>();
Http3\Http3FrameWriterTests.cs (2)
18private readonly MemoryPool<byte> _dirtyMemoryPool; 33var dirtyMemoryPool = new Mock<MemoryPool<byte>>();
HttpResponseHeadersTests.cs (1)
24using (var memoryPool = PinnedBlockMemoryPoolFactory.Create())
MemoryPoolTests.cs (5)
12protected abstract MemoryPool<byte> CreatePool(); 17var memoryPool = CreatePool(); 24var memoryPool = CreatePool(); 33var memoryPool = CreatePool(); 43var memoryPool = CreatePool();
PinnedBlockMemoryPoolTests.cs (3)
11protected override MemoryPool<byte> CreatePool() => new PinnedBlockMemoryPool(); 16var memoryPool = CreatePool(); 24var memoryPool = CreatePool();
PipelineExtensionTests.cs (1)
19private readonly MemoryPool<byte> _memoryPool = PinnedBlockMemoryPoolFactory.Create();
src\Servers\Kestrel\shared\test\TestContextFactory.cs (7)
53MemoryPool<byte> memoryPool = null, 66memoryPool ?? MemoryPool<byte>.Shared, 80MemoryPool<byte> memoryPool = null, 141MemoryPool<byte> memoryPool = null, 161memoryPool: memoryPool ?? MemoryPool<byte>.Shared, 182MemoryPool<byte> memoryPool = null, 211memoryPool: memoryPool ?? MemoryPool<byte>.Shared,
src\Servers\Kestrel\shared\test\TestServiceContext.cs (1)
76public Func<MemoryPool<byte>> MemoryPoolFactory { get; set; } = System.Buffers.PinnedBlockMemoryPoolFactory.Create;
src\Shared\Buffers.MemoryPool\DiagnosticMemoryPool.cs (2)
13private readonly MemoryPool<byte> _pool; 34public DiagnosticMemoryPool(MemoryPool<byte> pool, bool allowLateReturn = false, bool rentTracking = false)
src\Shared\Buffers.MemoryPool\MemoryPoolFactory.cs (2)
8public static MemoryPool<byte> Create() 17public static MemoryPool<byte> CreatePinnedBlockMemoryPool()
StartLineTests.cs (1)
21private MemoryPool<byte> MemoryPool { get; }
TestHelpers\TestInput.cs (1)
23private readonly MemoryPool<byte> _memoryPool;
Microsoft.AspNetCore.Server.Kestrel.Microbenchmarks (29)
ChunkWriterBenchmark.cs (1)
18private MemoryPool<byte> _memoryPool;
HeaderCollectionBenchmark.cs (1)
327var memoryPool = PinnedBlockMemoryPoolFactory.Create();
Http1ConnectionBenchmark.cs (1)
30var memoryPool = PinnedBlockMemoryPoolFactory.Create();
Http1ConnectionParsingOverheadBenchmark.cs (1)
26var memoryPool = PinnedBlockMemoryPoolFactory.Create();
Http1LargeWritingBenchmark.cs (1)
22private MemoryPool<byte> _memoryPool;
Http1ReadingBenchmark.cs (1)
31private MemoryPool<byte> _memoryPool;
Http1WritingBenchmark.cs (1)
30private MemoryPool<byte> _memoryPool;
Http2\Http2ConnectionBenchmarkBase.cs (1)
25private MemoryPool<byte> _memoryPool;
Http2\Http2FrameWriterBenchmark.cs (1)
19private MemoryPool<byte> _memoryPool;
HttpProtocolFeatureCollection.cs (1)
229var memoryPool = PinnedBlockMemoryPoolFactory.Create();
PipeThroughputBenchmark.cs (1)
17private MemoryPool<byte> _memoryPool;
RequestParsingBenchmark.cs (1)
18private MemoryPool<byte> _memoryPool;
ResponseHeaderCollectionBenchmark.cs (1)
175var memoryPool = PinnedBlockMemoryPoolFactory.Create();
src\Servers\Kestrel\shared\test\Http3\Http3InMemory.cs (3)
77internal readonly MemoryPool<byte> _memoryPool = PinnedBlockMemoryPoolFactory.Create(); 363public static PipeOptions GetInputPipeOptions(ServiceContext serviceContext, MemoryPool<byte> memoryPool, PipeScheduler writerScheduler) => new PipeOptions 374public static PipeOptions GetOutputPipeOptions(ServiceContext serviceContext, MemoryPool<byte> memoryPool, PipeScheduler readerScheduler) => new PipeOptions
src\Servers\Kestrel\shared\test\TestContextFactory.cs (7)
53MemoryPool<byte> memoryPool = null, 66memoryPool ?? MemoryPool<byte>.Shared, 80MemoryPool<byte> memoryPool = null, 141MemoryPool<byte> memoryPool = null, 161memoryPool: memoryPool ?? MemoryPool<byte>.Shared, 182MemoryPool<byte> memoryPool = null, 211memoryPool: memoryPool ?? MemoryPool<byte>.Shared,
src\Servers\Kestrel\shared\TransportConnection.cs (1)
38public virtual MemoryPool<byte> MemoryPool { get; } = default!;
src\Servers\Kestrel\shared\TransportConnection.FeatureCollection.cs (1)
19MemoryPool<byte> IMemoryPoolFeature.MemoryPool => MemoryPool;
src\Shared\Buffers.MemoryPool\DiagnosticMemoryPool.cs (2)
13private readonly MemoryPool<byte> _pool; 34public DiagnosticMemoryPool(MemoryPool<byte> pool, bool allowLateReturn = false, bool rentTracking = false)
src\Shared\Buffers.MemoryPool\MemoryPoolFactory.cs (2)
8public static MemoryPool<byte> Create() 17public static MemoryPool<byte> CreatePinnedBlockMemoryPool()
Microsoft.AspNetCore.Server.Kestrel.Transport.NamedPipes (10)
Internal\NamedPipeConnection.cs (2)
39MemoryPool<byte> memoryPool, 60public override MemoryPool<byte> MemoryPool { get; }
Internal\NamedPipeConnectionListener.cs (1)
27private readonly MemoryPool<byte> _memoryPool;
NamedPipeTransportOptions.cs (1)
119internal Func<MemoryPool<byte>> MemoryPoolFactory { get; set; } = PinnedBlockMemoryPoolFactory.Create;
src\Servers\Kestrel\shared\TransportConnection.cs (1)
38public virtual MemoryPool<byte> MemoryPool { get; } = default!;
src\Servers\Kestrel\shared\TransportConnection.FeatureCollection.cs (1)
19MemoryPool<byte> IMemoryPoolFeature.MemoryPool => MemoryPool;
src\Shared\Buffers.MemoryPool\DiagnosticMemoryPool.cs (2)
13private readonly MemoryPool<byte> _pool; 34public DiagnosticMemoryPool(MemoryPool<byte> pool, bool allowLateReturn = false, bool rentTracking = false)
src\Shared\Buffers.MemoryPool\MemoryPoolFactory.cs (2)
8public static MemoryPool<byte> Create() 17public static MemoryPool<byte> CreatePinnedBlockMemoryPool()
Microsoft.AspNetCore.Server.Kestrel.Transport.Quic (9)
Internal\QuicStreamContext.cs (1)
73public override MemoryPool<byte> MemoryPool { get; }
src\Servers\Kestrel\shared\TransportConnection.cs (1)
38public virtual MemoryPool<byte> MemoryPool { get; } = default!;
src\Servers\Kestrel\shared\TransportConnection.FeatureCollection.cs (1)
19MemoryPool<byte> IMemoryPoolFeature.MemoryPool => MemoryPool;
src\Servers\Kestrel\shared\TransportMultiplexedConnection.cs (1)
32public virtual MemoryPool<byte> MemoryPool { get; } = default!;
src\Servers\Kestrel\shared\TransportMultiplexedConnection.FeatureCollection.cs (1)
16MemoryPool<byte> IMemoryPoolFeature.MemoryPool => MemoryPool;
src\Shared\Buffers.MemoryPool\DiagnosticMemoryPool.cs (2)
13private readonly MemoryPool<byte> _pool; 34public DiagnosticMemoryPool(MemoryPool<byte> pool, bool allowLateReturn = false, bool rentTracking = false)
src\Shared\Buffers.MemoryPool\MemoryPoolFactory.cs (2)
8public static MemoryPool<byte> Create() 17public static MemoryPool<byte> CreatePinnedBlockMemoryPool()
Microsoft.AspNetCore.Server.Kestrel.Transport.Sockets (14)
Client\SocketConnectionFactory.cs (1)
18private readonly MemoryPool<byte> _memoryPool;
Internal\SocketConnection.cs (2)
35MemoryPool<byte> memoryPool, 75public override MemoryPool<byte> MemoryPool { get; }
SocketConnectionContextFactory.cs (3)
50var memoryPool = _options.MemoryPoolFactory(); 65var memoryPool = _options.MemoryPoolFactory(); 123public MemoryPool<byte> MemoryPool { get; init; } = default!;
SocketConnectionFactoryOptions.cs (1)
70internal Func<MemoryPool<byte>> MemoryPoolFactory { get; set; } = PinnedBlockMemoryPoolFactory.Create;
SocketTransportOptions.cs (1)
169internal Func<MemoryPool<byte>> MemoryPoolFactory { get; set; } = System.Buffers.PinnedBlockMemoryPoolFactory.Create;
src\Servers\Kestrel\shared\TransportConnection.cs (1)
38public virtual MemoryPool<byte> MemoryPool { get; } = default!;
src\Servers\Kestrel\shared\TransportConnection.FeatureCollection.cs (1)
19MemoryPool<byte> IMemoryPoolFeature.MemoryPool => MemoryPool;
src\Shared\Buffers.MemoryPool\DiagnosticMemoryPool.cs (2)
13private readonly MemoryPool<byte> _pool; 34public DiagnosticMemoryPool(MemoryPool<byte> pool, bool allowLateReturn = false, bool rentTracking = false)
src\Shared\Buffers.MemoryPool\MemoryPoolFactory.cs (2)
8public static MemoryPool<byte> Create() 17public static MemoryPool<byte> CreatePinnedBlockMemoryPool()
Microsoft.AspNetCore.Shared.Tests (4)
src\Shared\HttpSys\RequestProcessing\NativeRequestContext.cs (2)
43internal NativeRequestContext(MemoryPool<byte> memoryPool, uint? bufferSize, ulong requestId, bool useLatin1) 63_backingBuffer = MemoryPool<byte>.Shared.Rent(newSize);
src\Shared\ServerInfrastructure\MemoryPoolExtensions.cs (2)
18public static int GetMinimumSegmentSize(this MemoryPool<byte> pool) 28public static int GetMinimumAllocSize(this MemoryPool<byte> pool)
mscorlib (1)
mscorlib.cs (1)
40[assembly:System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Buffers.MemoryPool<>))]
netstandard (1)
netstandard.cs (1)
68[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Buffers.MemoryPool<>))]
Sockets.BindTests (3)
src\Servers\Kestrel\shared\test\TestServiceContext.cs (1)
76public Func<MemoryPool<byte>> MemoryPoolFactory { get; set; } = System.Buffers.PinnedBlockMemoryPoolFactory.Create;
src\Servers\Kestrel\shared\test\TransportTestHelpers\DiagnosticMemoryPoolFactory.cs (1)
27public MemoryPool<byte> Create()
src\Servers\Kestrel\test\Sockets.FunctionalTests\TransportSelector.cs (1)
13public static IHostBuilder GetHostBuilder(Func<MemoryPool<byte>> memoryPoolFactory = null,
Sockets.FunctionalTests (4)
src\Servers\Kestrel\shared\test\TestServiceContext.cs (1)
76public Func<MemoryPool<byte>> MemoryPoolFactory { get; set; } = System.Buffers.PinnedBlockMemoryPoolFactory.Create;
src\Servers\Kestrel\shared\test\TransportTestHelpers\DiagnosticMemoryPoolFactory.cs (1)
27public MemoryPool<byte> Create()
src\Servers\Kestrel\test\FunctionalTests\MaxRequestBufferSizeTests.cs (1)
309Func<MemoryPool<byte>> memoryPoolFactory = null)
TransportSelector.cs (1)
13public static IHostBuilder GetHostBuilder(Func<MemoryPool<byte>> memoryPoolFactory = null,
System.IO.Pipelines (21)
System\IO\Pipelines\Pipe.cs (1)
235MemoryPool<byte>? pool = null;
System\IO\Pipelines\PipeOptions.cs (6)
27MemoryPool<byte>? pool = null, 79Pool = pool ?? MemoryPool<byte>.Shared; 80IsDefaultSharedMemoryPool = Pool == MemoryPool<byte>.Shared; 112/// <summary>Gets the <see cref="System.Buffers.MemoryPool{T}" /> object used for buffer management.</summary> 114public MemoryPool<byte> Pool { get; } 117/// Returns true if Pool is <see cref="MemoryPool{Byte}"/>.Shared
System\IO\Pipelines\StreamPipeReader.cs (1)
61private MemoryPool<byte> Pool => _options.Pool;
System\IO\Pipelines\StreamPipeReaderOptions.cs (7)
22public StreamPipeReaderOptions(MemoryPool<byte>? pool, int bufferSize, int minimumReadSize, bool leaveOpen) : 34public StreamPipeReaderOptions(MemoryPool<byte>? pool = null, int bufferSize = -1, int minimumReadSize = -1, bool leaveOpen = false, bool useZeroByteReads = false) 36Pool = pool ?? MemoryPool<byte>.Shared; 38IsDefaultSharedMemoryPool = Pool == MemoryPool<byte>.Shared; 67/// <summary>Gets the <see cref="System.Buffers.MemoryPool{T}" /> to use when allocating memory.</summary> 69public MemoryPool<byte> Pool { get; } 80/// Returns true if Pool is <see cref="MemoryPool{Byte}"/>.Shared
System\IO\Pipelines\StreamPipeWriter.cs (2)
25private readonly MemoryPool<byte>? _pool; 59_pool = options.Pool == MemoryPool<byte>.Shared ? null : options.Pool;
System\IO\Pipelines\StreamPipeWriterOptions.cs (4)
19public StreamPipeWriterOptions(MemoryPool<byte>? pool = null, int minimumBufferSize = -1, bool leaveOpen = false) 21Pool = pool ?? MemoryPool<byte>.Shared; 35/// <summary>Gets the <see cref="System.Buffers.MemoryPool{T}" /> to use when allocating memory.</summary> 37public MemoryPool<byte> Pool { get; }
System.Memory (1)
System\Buffers\MemoryPool.cs (1)
18public static MemoryPool<T> Shared => s_shared;