RequestTimeoutsIEndpointConventionBuilderExtensions.WithRequestTimeout 方法

定义

重载

WithRequestTimeout(IEndpointConventionBuilder, RequestTimeoutPolicy)

指定终结点 () 的超时策略。

WithRequestTimeout(IEndpointConventionBuilder, String)

指定终结点 () 的超时策略。

WithRequestTimeout(IEndpointConventionBuilder, TimeSpan)

指定终结点 () 超时。

WithRequestTimeout(IEndpointConventionBuilder, RequestTimeoutPolicy)

Source:
RequestTimeoutsIEndpointConventionBuilderExtensions.cs

指定终结点 () 的超时策略。

public static Microsoft.AspNetCore.Builder.IEndpointConventionBuilder WithRequestTimeout (this Microsoft.AspNetCore.Builder.IEndpointConventionBuilder builder, Microsoft.AspNetCore.Http.Timeouts.RequestTimeoutPolicy policy);
static member WithRequestTimeout : Microsoft.AspNetCore.Builder.IEndpointConventionBuilder * Microsoft.AspNetCore.Http.Timeouts.RequestTimeoutPolicy -> Microsoft.AspNetCore.Builder.IEndpointConventionBuilder
<Extension()>
Public Function WithRequestTimeout (builder As IEndpointConventionBuilder, policy As RequestTimeoutPolicy) As IEndpointConventionBuilder

参数

builder
IEndpointConventionBuilder

终结点约定生成器。

policy
RequestTimeoutPolicy

请求超时策略。

返回

原始约定生成器参数。

适用于

WithRequestTimeout(IEndpointConventionBuilder, String)

Source:
RequestTimeoutsIEndpointConventionBuilderExtensions.cs

指定终结点 () 的超时策略。

public static Microsoft.AspNetCore.Builder.IEndpointConventionBuilder WithRequestTimeout (this Microsoft.AspNetCore.Builder.IEndpointConventionBuilder builder, string policyName);
static member WithRequestTimeout : Microsoft.AspNetCore.Builder.IEndpointConventionBuilder * string -> Microsoft.AspNetCore.Builder.IEndpointConventionBuilder
<Extension()>
Public Function WithRequestTimeout (builder As IEndpointConventionBuilder, policyName As String) As IEndpointConventionBuilder

参数

builder
IEndpointConventionBuilder

终结点约定生成器。

policyName
String

要应用于终结点 () 的策略的名称 (不区分大小写) 。

返回

原始约定生成器参数。

适用于

WithRequestTimeout(IEndpointConventionBuilder, TimeSpan)

Source:
RequestTimeoutsIEndpointConventionBuilderExtensions.cs

指定终结点 () 超时。

public static Microsoft.AspNetCore.Builder.IEndpointConventionBuilder WithRequestTimeout (this Microsoft.AspNetCore.Builder.IEndpointConventionBuilder builder, TimeSpan timeout);
static member WithRequestTimeout : Microsoft.AspNetCore.Builder.IEndpointConventionBuilder * TimeSpan -> Microsoft.AspNetCore.Builder.IEndpointConventionBuilder
<Extension()>
Public Function WithRequestTimeout (builder As IEndpointConventionBuilder, timeout As TimeSpan) As IEndpointConventionBuilder

参数

builder
IEndpointConventionBuilder

终结点约定生成器。

timeout
TimeSpan

要应用于终结点的超时 () 。

返回

原始约定生成器参数。

适用于