HttpResiliencePipelineBuilderExtensions.SelectPipelineBy 方法
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
指示基础生成器通过自定义选择器选择管道实例。
public:
[System::Runtime::CompilerServices::Extension]
static Microsoft::Extensions::Http::Resilience::IHttpResiliencePipelineBuilder ^ SelectPipelineBy(Microsoft::Extensions::Http::Resilience::IHttpResiliencePipelineBuilder ^ builder, Func<IServiceProvider ^, Func<System::Net::Http::HttpRequestMessage ^, System::String ^> ^> ^ selectorFactory);
public static Microsoft.Extensions.Http.Resilience.IHttpResiliencePipelineBuilder SelectPipelineBy (this Microsoft.Extensions.Http.Resilience.IHttpResiliencePipelineBuilder builder, Func<IServiceProvider,Func<System.Net.Http.HttpRequestMessage,string>> selectorFactory);
static member SelectPipelineBy : Microsoft.Extensions.Http.Resilience.IHttpResiliencePipelineBuilder * Func<IServiceProvider, Func<System.Net.Http.HttpRequestMessage, string>> -> Microsoft.Extensions.Http.Resilience.IHttpResiliencePipelineBuilder
<Extension()>
Public Function SelectPipelineBy (builder As IHttpResiliencePipelineBuilder, selectorFactory As Func(Of IServiceProvider, Func(Of HttpRequestMessage, String))) As IHttpResiliencePipelineBuilder
参数
- builder
- IHttpResiliencePipelineBuilder
生成器实例。
- selectorFactory
- Func<IServiceProvider,Func<HttpRequestMessage,String>>
返回密钥选择器的工厂。
返回
builder
的值。
注解
管道密钥用于指标和日志,因此不要返回任何敏感值。