HttpClientLatencyTelemetryExtensions.AddHttpClientLatencyTelemetry 方法
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
重载
AddHttpClientLatencyTelemetry(IServiceCollection) |
添加 以 DelegatingHandler 收集延迟信息并扩充所有 http 客户端的传出请求日志。 |
AddHttpClientLatencyTelemetry(IServiceCollection, IConfigurationSection) |
添加 以 DelegatingHandler 收集延迟信息并扩充所有 http 客户端的传出请求日志。 |
AddHttpClientLatencyTelemetry(IServiceCollection, Action<HttpClientLatencyTelemetryOptions>) |
添加 以 DelegatingHandler 收集延迟信息并扩充所有 http 客户端的传出请求日志。 |
AddHttpClientLatencyTelemetry(IServiceCollection)
添加 以 DelegatingHandler 收集延迟信息并扩充所有 http 客户端的传出请求日志。
public:
[System::Runtime::CompilerServices::Extension]
static Microsoft::Extensions::DependencyInjection::IServiceCollection ^ AddHttpClientLatencyTelemetry(Microsoft::Extensions::DependencyInjection::IServiceCollection ^ services);
public static Microsoft.Extensions.DependencyInjection.IServiceCollection AddHttpClientLatencyTelemetry (this Microsoft.Extensions.DependencyInjection.IServiceCollection services);
static member AddHttpClientLatencyTelemetry : Microsoft.Extensions.DependencyInjection.IServiceCollection -> Microsoft.Extensions.DependencyInjection.IServiceCollection
<Extension()>
Public Function AddHttpClientLatencyTelemetry (services As IServiceCollection) As IServiceCollection
参数
- services
- IServiceCollection
返回
services
的值。
注解
此扩展为所有 http 客户端全局配置延迟信息收集。
适用于
AddHttpClientLatencyTelemetry(IServiceCollection, IConfigurationSection)
添加 以 DelegatingHandler 收集延迟信息并扩充所有 http 客户端的传出请求日志。
public:
[System::Runtime::CompilerServices::Extension]
static Microsoft::Extensions::DependencyInjection::IServiceCollection ^ AddHttpClientLatencyTelemetry(Microsoft::Extensions::DependencyInjection::IServiceCollection ^ services, Microsoft::Extensions::Configuration::IConfigurationSection ^ section);
public static Microsoft.Extensions.DependencyInjection.IServiceCollection AddHttpClientLatencyTelemetry (this Microsoft.Extensions.DependencyInjection.IServiceCollection services, Microsoft.Extensions.Configuration.IConfigurationSection section);
static member AddHttpClientLatencyTelemetry : Microsoft.Extensions.DependencyInjection.IServiceCollection * Microsoft.Extensions.Configuration.IConfigurationSection -> Microsoft.Extensions.DependencyInjection.IServiceCollection
<Extension()>
Public Function AddHttpClientLatencyTelemetry (services As IServiceCollection, section As IConfigurationSection) As IServiceCollection
参数
- services
- IServiceCollection
返回
services
的值。
注解
此扩展为所有 http 客户端配置全局传出请求日志自动收集。
适用于
AddHttpClientLatencyTelemetry(IServiceCollection, Action<HttpClientLatencyTelemetryOptions>)
添加 以 DelegatingHandler 收集延迟信息并扩充所有 http 客户端的传出请求日志。
public:
[System::Runtime::CompilerServices::Extension]
static Microsoft::Extensions::DependencyInjection::IServiceCollection ^ AddHttpClientLatencyTelemetry(Microsoft::Extensions::DependencyInjection::IServiceCollection ^ services, Action<Microsoft::Extensions::Http::Latency::HttpClientLatencyTelemetryOptions ^> ^ configure);
public static Microsoft.Extensions.DependencyInjection.IServiceCollection AddHttpClientLatencyTelemetry (this Microsoft.Extensions.DependencyInjection.IServiceCollection services, Action<Microsoft.Extensions.Http.Latency.HttpClientLatencyTelemetryOptions> configure);
static member AddHttpClientLatencyTelemetry : Microsoft.Extensions.DependencyInjection.IServiceCollection * Action<Microsoft.Extensions.Http.Latency.HttpClientLatencyTelemetryOptions> -> Microsoft.Extensions.DependencyInjection.IServiceCollection
<Extension()>
Public Function AddHttpClientLatencyTelemetry (services As IServiceCollection, configure As Action(Of HttpClientLatencyTelemetryOptions)) As IServiceCollection
参数
- services
- IServiceCollection
- configure
- Action<HttpClientLatencyTelemetryOptions>
要配置的 HttpClientLatencyTelemetryOptions 委托。
返回
services
的值。
注解
此扩展为所有 http 客户端配置全局传出请求日志自动收集。