Table of Contents

Class MetadataBuilderIdentityExtensions

Namespace
Excalibur.Dispatch
Assembly
Excalibur.Dispatch.Abstractions.dll

Extension methods for setting identity and security properties on IMessageMetadataBuilder.

public static class MetadataBuilderIdentityExtensions
Inheritance
MetadataBuilderIdentityExtensions
Inherited Members

Methods

WithBaggage(IMessageMetadataBuilder, string?)

Sets the W3C baggage for distributed tracing context propagation.

public static IMessageMetadataBuilder WithBaggage(this IMessageMetadataBuilder builder, string? baggage)

Parameters

builder IMessageMetadataBuilder

The builder instance.

baggage string

The W3C baggage header value.

Returns

IMessageMetadataBuilder

The builder instance for method chaining.

WithClaims(IMessageMetadataBuilder, IEnumerable<Claim>?)

Sets the security claims associated with the message.

public static IMessageMetadataBuilder WithClaims(this IMessageMetadataBuilder builder, IEnumerable<Claim>? claims)

Parameters

builder IMessageMetadataBuilder

The builder instance.

claims IEnumerable<Claim>

The collection of security claims.

Returns

IMessageMetadataBuilder

The builder instance for method chaining.

WithExternalId(IMessageMetadataBuilder, string?)

Sets an external identifier from an external system or integration.

public static IMessageMetadataBuilder WithExternalId(this IMessageMetadataBuilder builder, string? externalId)

Parameters

builder IMessageMetadataBuilder

The builder instance.

externalId string

The external system identifier.

Returns

IMessageMetadataBuilder

The builder instance for method chaining.

WithRoles(IMessageMetadataBuilder, IEnumerable<string>?)

Sets the security roles associated with the message.

public static IMessageMetadataBuilder WithRoles(this IMessageMetadataBuilder builder, IEnumerable<string>? roles)

Parameters

builder IMessageMetadataBuilder

The builder instance.

roles IEnumerable<string>

The collection of role identifiers.

Returns

IMessageMetadataBuilder

The builder instance for method chaining.

WithTenantId(IMessageMetadataBuilder, string?)

Sets the tenant identifier for multi-tenant scenarios.

public static IMessageMetadataBuilder WithTenantId(this IMessageMetadataBuilder builder, string? tenantId)

Parameters

builder IMessageMetadataBuilder

The builder instance.

tenantId string

The identifier of the tenant.

Returns

IMessageMetadataBuilder

The builder instance for method chaining.

WithTraceParent(IMessageMetadataBuilder, string?)

Sets the W3C trace parent for distributed tracing.

public static IMessageMetadataBuilder WithTraceParent(this IMessageMetadataBuilder builder, string? traceParent)

Parameters

builder IMessageMetadataBuilder

The builder instance.

traceParent string

The W3C trace parent header value.

Returns

IMessageMetadataBuilder

The builder instance for method chaining.

WithTraceState(IMessageMetadataBuilder, string?)

Sets the W3C trace state for distributed tracing.

public static IMessageMetadataBuilder WithTraceState(this IMessageMetadataBuilder builder, string? traceState)

Parameters

builder IMessageMetadataBuilder

The builder instance.

traceState string

The W3C trace state header value.

Returns

IMessageMetadataBuilder

The builder instance for method chaining.

WithUserId(IMessageMetadataBuilder, string?)

Sets the user identifier associated with this message.

public static IMessageMetadataBuilder WithUserId(this IMessageMetadataBuilder builder, string? userId)

Parameters

builder IMessageMetadataBuilder

The builder instance.

userId string

The identifier of the user.

Returns

IMessageMetadataBuilder

The builder instance for method chaining.