Skip to content

ServiceCollectionExtensions Methods

Provides extension methods for configuring and integrating the Orleans Dashboard.

AddDashboard(IClientBuilder, Action<DashboardOptions>)

staticextension
View source
public static IClientBuilder AddDashboard(this IClientBuilder clientBuilder, Action<DashboardOptions>? configureOptions = null)
Adds Orleans Dashboard services to an Orleans client builder. This allows you to host the Orleans Dashboard application on an Orleans client, so long as the silos also have the dashboard added.

Parameters

clientBuilderIClientBuilder
The client builder.
configureOptionsAction<DashboardOptions>
Optional configuration action for DashboardOptions.

Returns

The client builder for method chaining.

Exceptions

System.ArgumentNullException
clientBuilder is null.

AddDashboard(ISiloBuilder, Action<DashboardOptions>)

staticextension
View source
public static ISiloBuilder AddDashboard(this ISiloBuilder siloBuilder, Action<DashboardOptions>? configureOptions = null)
Adds Orleans Dashboard services to the silo builder.

Parameters

siloBuilderISiloBuilder
The silo builder.
configureOptionsAction<DashboardOptions>
Optional configuration action for DashboardOptions.

Returns

The silo builder for method chaining.

Exceptions

System.ArgumentNullException
siloBuilder is null.

MapOrleansDashboard(IEndpointRouteBuilder, string?)

staticextension
View source
public static RouteGroupBuilder MapOrleansDashboard(this IEndpointRouteBuilder endpoints, string? routePrefix = null)
Maps Orleans Dashboard endpoints using ASP.NET Core minimal APIs. The returned route group supports authentication, authorization, and other endpoint configuration.

Parameters

endpointsIEndpointRouteBuilder
The application's endpoint route builder.
routePrefixstring?
The optional base route for the dashboard endpoints.

Returns

The dashboard route group.

Exceptions

System.ArgumentNullException
endpoints is null.

Examples

// Basic usage
app.MapOrleansDashboard();
// With authentication
app.MapOrleansDashboard().RequireAuthorization();
// With custom base path
app.MapOrleansDashboard(routePrefix: "/dashboard");