Table of Contents

Class UserIdentifierQuotaContext

Namespace
FoundationaLLM.Common.Services.Quota
Assembly
FoundationaLLM.Common.dll

Implements a quota context partitioned by user identifier.

public class UserIdentifierQuotaContext : QuotaContextBase
Inheritance
UserIdentifierQuotaContext
Inherited Members
Extension Methods

Constructors

UserIdentifierQuotaContext(string, QuotaDefinition, ILogger)

Implements a quota context partitioned by user identifier.

public UserIdentifierQuotaContext(string quotaServiceIdentifier, QuotaDefinition quota, ILogger logger)

Parameters

quotaServiceIdentifier string

The identifier of the QuotaService instance managing this quota context.

quota QuotaDefinition

The QuotaDefinition providing the quota configuration.

logger ILogger

The logger used for logging.

Methods

GetQuotaMetricPartition(string, string)

Gets the quota metric partition that corresponds to the specified user identifier and/or user principal name.

protected override QuotaMetricPartition GetQuotaMetricPartition(string userIdentifier, string userPrincipalName)

Parameters

userIdentifier string

The user identifier used to get the quota metric partition

userPrincipalName string

The user principal name used to get the quota metric partition.

Returns

QuotaMetricPartition

A QuotaMetricPartition instance.