Skip to content
ModularityKit.Mutator ModularityKit.Mutator Docs
  • Home
  • Core
  • Governance
  • Redis
  • API
Search Results for

    Show / Hide Table of Contents

    Class MutationMetrics

    Captures execution metrics for a single mutation operation.

    Inheritance
    object
    MutationMetrics
    Implements
    IEquatable<MutationMetrics>
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: ModularityKit.Mutator.Abstractions.Metrics
    Assembly: ModularityKit.Mutator.dll
    Syntax
    public sealed record MutationMetrics : IEquatable<MutationMetrics>
    Remarks

    MutationMetrics provides detailed performance and operational metrics for a mutation, including timing, policy evaluations, state changes, memory usage, and caching behavior. These metrics are typically collected by the Mutators framework for auditing, monitoring, and optimization purposes.

    Key considerations:

    • ExecutionTime measures the total duration of the mutation.
    • ValidationTime measures time spent validating the mutation.
    • PolicyEvaluationTime measures time spent evaluating policies.
    • ValidatedRules and EvaluatedPolicies track the number of rules/policies processed.
    • ChangesCount counts state changes applied.
    • StateSize and MemoryUsed provide insights into resource consumption.
    • UsedCache indicates if a cache was leveraged.
    • AdditionalMetrics allows extensibility for custom metrics.

    Properties

    | Edit this page View Source

    AdditionalMetrics

    Additional custom metrics.

    Declaration
    public IReadOnlyDictionary<string, object> AdditionalMetrics { get; init; }
    Property Value
    Type Description
    IReadOnlyDictionary<string, object>
    | Edit this page View Source

    ChangesCount

    Number of state changes applied.

    Declaration
    public int ChangesCount { get; init; }
    Property Value
    Type Description
    int
    | Edit this page View Source

    EvaluatedPolicies

    Number of policies evaluated during the mutation.

    Declaration
    public int EvaluatedPolicies { get; init; }
    Property Value
    Type Description
    int
    | Edit this page View Source

    ExecutionTime

    Total execution time of the mutation.

    Declaration
    public TimeSpan ExecutionTime { get; init; }
    Property Value
    Type Description
    TimeSpan
    | Edit this page View Source

    MemoryUsed

    Memory used during mutation execution (in bytes).

    Declaration
    public long? MemoryUsed { get; init; }
    Property Value
    Type Description
    long?
    | Edit this page View Source

    PolicyEvaluationTime

    Time spent evaluating policies.

    Declaration
    public TimeSpan PolicyEvaluationTime { get; init; }
    Property Value
    Type Description
    TimeSpan
    | Edit this page View Source

    RecordedAt

    Timestamp when the mutation was recorded.

    Declaration
    public DateTimeOffset RecordedAt { get; init; }
    Property Value
    Type Description
    DateTimeOffset
    | Edit this page View Source

    StateSize

    Size of the state before the mutation (in bytes, if applicable).

    Declaration
    public long? StateSize { get; init; }
    Property Value
    Type Description
    long?
    | Edit this page View Source

    UsedCache

    Indicates whether a cache was used.

    Declaration
    public bool UsedCache { get; init; }
    Property Value
    Type Description
    bool
    | Edit this page View Source

    ValidatedRules

    Number of rules validated during the mutation.

    Declaration
    public int ValidatedRules { get; init; }
    Property Value
    Type Description
    int
    | Edit this page View Source

    ValidationTime

    Time spent validating the mutation.

    Declaration
    public TimeSpan ValidationTime { get; init; }
    Property Value
    Type Description
    TimeSpan

    Implements

    IEquatable<T>
    • Edit this page
    • View Source
    In this article
    ModularityKit.Mutator Generated from XML docs and published from main. Back to top