Share via


ResourceBuilderExtensions.AsHttp2Service<T> Method

Definition

Configures a resource to mark all endpoints' transport as HTTP/2. This is useful for HTTP/2 services that need prior knowledge.

public static Aspire.Hosting.ApplicationModel.IResourceBuilder<T> AsHttp2Service<T> (this Aspire.Hosting.ApplicationModel.IResourceBuilder<T> builder) where T : Aspire.Hosting.ApplicationModel.IResourceWithEndpoints;
static member AsHttp2Service : Aspire.Hosting.ApplicationModel.IResourceBuilder<'T (requires 'T :> Aspire.Hosting.ApplicationModel.IResourceWithEndpoints)> -> Aspire.Hosting.ApplicationModel.IResourceBuilder<'T (requires 'T :> Aspire.Hosting.ApplicationModel.IResourceWithEndpoints)> (requires 'T :> Aspire.Hosting.ApplicationModel.IResourceWithEndpoints)
<Extension()>
Public Function AsHttp2Service(Of T As IResourceWithEndpoints) (builder As IResourceBuilder(Of T)) As IResourceBuilder(Of T)

Type Parameters

T

The resource type.

Parameters

builder
IResourceBuilder<T>

The resource builder.

Returns

The IResourceBuilder<T>.

Applies to