1 write to ServiceContext
Microsoft.AspNetCore.Server.Kestrel.Core (1)
Internal\KestrelServerImpl.cs (1)
68ServiceContext = serviceContext;
14 references to ServiceContext
Microsoft.AspNetCore.Server.Kestrel.Core (9)
Internal\KestrelServerImpl.cs (9)
74_transportManager = new TransportManager(_transportFactories, _multiplexedTransportFactories, _httpsConfigurationService, ServiceContext); 115public KestrelServerOptions Options => ServiceContext.ServerOptions; 120private KestrelTrace Trace => ServiceContext.Log; 137ServiceContext.Heartbeat?.Start(); 197options.UseHttpServer(ServiceContext, application, options.Protocols, addAltSvcHeader); 201connectionDelegate = EnforceConnectionLimit(connectionDelegate, Options.Limits.MaxConcurrentConnections, Trace, ServiceContext.Metrics); 216options.UseHttp3Server(ServiceContext, application, options.Protocols, addAltSvcHeader); 220multiplexedConnectionDelegate = EnforceConnectionLimit(multiplexedConnectionDelegate, Options.Limits.MaxConcurrentConnections, Trace, ServiceContext.Metrics); 253ServiceContext.Heartbeat?.Dispose();
Microsoft.AspNetCore.Server.Kestrel.Tests (5)
WebHostBuilderKestrelExtensionsTests.cs (5)
119Assert.NotNull(server.ServiceContext.DiagnosticSource); 120Assert.IsType<KestrelMetrics>(server.ServiceContext.Metrics); 121Assert.Equal(PipeScheduler.ThreadPool, server.ServiceContext.Scheduler); 122Assert.Equal(TimeProvider.System, server.ServiceContext.TimeProvider); 124var handlers = (IHeartbeatHandler[])typeof(Heartbeat).GetField("_callbacks", BindingFlags.NonPublic | BindingFlags.Instance).GetValue(server.ServiceContext.Heartbeat);