共用方式為


IDistributedApplicationResourceBuilderExtensions.WithDaprSidecar Method

Definition

Overloads

WithDaprSidecar<T>(IResourceBuilder<T>, DaprSidecarOptions)

Ensures that a Dapr sidecar is started for the resource.

WithDaprSidecar<T>(IResourceBuilder<T>, Action<IResourceBuilder<IDaprSidecarResource>>)

Ensures that a Dapr sidecar is started for the resource.

WithDaprSidecar<T>(IResourceBuilder<T>, String)

Ensures that a Dapr sidecar is started for the resource.

WithDaprSidecar<T>(IResourceBuilder<T>, DaprSidecarOptions)

Source:
IDistributedApplicationComponentBuilderExtensions.cs
Source:
IDistributedApplicationComponentBuilderExtensions.cs

Ensures that a Dapr sidecar is started for the resource.

public static Aspire.Hosting.ApplicationModel.IResourceBuilder<T> WithDaprSidecar<T> (this Aspire.Hosting.ApplicationModel.IResourceBuilder<T> builder, Aspire.Hosting.Dapr.DaprSidecarOptions? options = default) where T : Aspire.Hosting.ApplicationModel.IResource;
static member WithDaprSidecar : Aspire.Hosting.ApplicationModel.IResourceBuilder<'T (requires 'T :> Aspire.Hosting.ApplicationModel.IResource)> * Aspire.Hosting.Dapr.DaprSidecarOptions -> Aspire.Hosting.ApplicationModel.IResourceBuilder<'T (requires 'T :> Aspire.Hosting.ApplicationModel.IResource)> (requires 'T :> Aspire.Hosting.ApplicationModel.IResource)
<Extension()>
Public Function WithDaprSidecar(Of T As IResource) (builder As IResourceBuilder(Of T), Optional options As DaprSidecarOptions = Nothing) As IResourceBuilder(Of T)

Type Parameters

T

The type of the resource.

Parameters

builder
IResourceBuilder<T>

The resource builder instance.

options
DaprSidecarOptions

Options for configuring the Dapr sidecar, if any.

Returns

The resource builder instance.

Applies to

WithDaprSidecar<T>(IResourceBuilder<T>, Action<IResourceBuilder<IDaprSidecarResource>>)

Source:
IDistributedApplicationComponentBuilderExtensions.cs
Source:
IDistributedApplicationComponentBuilderExtensions.cs

Ensures that a Dapr sidecar is started for the resource.

public static Aspire.Hosting.ApplicationModel.IResourceBuilder<T> WithDaprSidecar<T> (this Aspire.Hosting.ApplicationModel.IResourceBuilder<T> builder, Action<Aspire.Hosting.ApplicationModel.IResourceBuilder<Aspire.Hosting.Dapr.IDaprSidecarResource>> configureSidecar) where T : Aspire.Hosting.ApplicationModel.IResource;
static member WithDaprSidecar : Aspire.Hosting.ApplicationModel.IResourceBuilder<'T (requires 'T :> Aspire.Hosting.ApplicationModel.IResource)> * Action<Aspire.Hosting.ApplicationModel.IResourceBuilder<Aspire.Hosting.Dapr.IDaprSidecarResource>> -> Aspire.Hosting.ApplicationModel.IResourceBuilder<'T (requires 'T :> Aspire.Hosting.ApplicationModel.IResource)> (requires 'T :> Aspire.Hosting.ApplicationModel.IResource)
<Extension()>
Public Function WithDaprSidecar(Of T As IResource) (builder As IResourceBuilder(Of T), configureSidecar As Action(Of IResourceBuilder(Of IDaprSidecarResource))) As IResourceBuilder(Of T)

Type Parameters

T

The type of the resource.

Parameters

builder
IResourceBuilder<T>

The resource builder instance.

configureSidecar
Action<IResourceBuilder<IDaprSidecarResource>>

A callback that can be use to configure the Dapr sidecar.

Returns

The resource builder instance.

Applies to

WithDaprSidecar<T>(IResourceBuilder<T>, String)

Source:
IDistributedApplicationComponentBuilderExtensions.cs
Source:
IDistributedApplicationComponentBuilderExtensions.cs

Ensures that a Dapr sidecar is started for the resource.

public static Aspire.Hosting.ApplicationModel.IResourceBuilder<T> WithDaprSidecar<T> (this Aspire.Hosting.ApplicationModel.IResourceBuilder<T> builder, string appId) where T : Aspire.Hosting.ApplicationModel.IResource;
static member WithDaprSidecar : Aspire.Hosting.ApplicationModel.IResourceBuilder<'T (requires 'T :> Aspire.Hosting.ApplicationModel.IResource)> * string -> Aspire.Hosting.ApplicationModel.IResourceBuilder<'T (requires 'T :> Aspire.Hosting.ApplicationModel.IResource)> (requires 'T :> Aspire.Hosting.ApplicationModel.IResource)
<Extension()>
Public Function WithDaprSidecar(Of T As IResource) (builder As IResourceBuilder(Of T), appId As String) As IResourceBuilder(Of T)

Type Parameters

T

The type of the resource.

Parameters

builder
IResourceBuilder<T>

The resource builder instance.

appId
String

The ID for the application, used for service discovery.

Returns

The resource builder instance.

Applies to