ModularityKit.Mutator.Governance 1.5.0

There is a newer version of this package available.
See the version list below for details.
dotnet add package ModularityKit.Mutator.Governance --version 1.5.0
                    
NuGet\Install-Package ModularityKit.Mutator.Governance -Version 1.5.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="ModularityKit.Mutator.Governance" Version="1.5.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="ModularityKit.Mutator.Governance" Version="1.5.0" />
                    
Directory.Packages.props
<PackageReference Include="ModularityKit.Mutator.Governance" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add ModularityKit.Mutator.Governance --version 1.5.0
                    
#r "nuget: ModularityKit.Mutator.Governance, 1.5.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package ModularityKit.Mutator.Governance@1.5.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=ModularityKit.Mutator.Governance&version=1.5.0
                    
Install as a Cake Addin
#tool nuget:?package=ModularityKit.Mutator.Governance&version=1.5.0
                    
Install as a Cake Tool

ModularityKit.Mutator.Governance

What it adds and governance lifecycle

Quick start

using ModularityKit.Mutator.Abstractions.Core;
using ModularityKit.Mutator.Abstractions.Requests;
using ModularityKit.Mutator.Governance.Abstractions.Storage;
using ModularityKit.Mutator.Governance.Runtime.Storage;

var store = new InMemoryMutationRequestStore();

var request = MutationRequestFactory.PendingApproval(
    stateId: "tenant-42:roles",
    stateType: "IamRoleState",
    mutationType: "GrantRoleMutation",
    intent: new MutationIntent
    {
        OperationName = "GrantRole",
        Category = "Security",
        Description = "Grant elevated role to tenant operator"
    },
    context: MutationContext.User("requester-1", "Requester One", "Incident escalation"),
    expectedStateVersion: "v10",
    approvalRequirements:
    [
        MutationApprovalRequirement.SingleActorStep("security-lead"),
        MutationApprovalRequirement.SingleActorStep("platform-owner")
    ]);

var persisted = await store.Create(request);
Console.WriteLine($"{persisted.RequestId} -> {persisted.Status}");

Primary APIs

Requests

  • MutationRequest
  • MutationRequestFactory
  • MutationRequestDecision
  • MutationRequestStatus
  • PendingMutationReason

Storage

  • IMutationRequestStore
  • InMemoryMutationRequestStore

Lifecycle

  • IMutationRequestLifecycleManager
  • MutationRequestLifecycleManager

Approval

  • IMutationRequestApprovalWorkflowManager
  • MutationRequestApprovalWorkflowManager
  • MutationApprovalRequirement

Queries

  • IMutationRequestQueryStore
  • MutationRequestQuery
  • MutationApprovalQuery
  • MutationRequestDecisionQuery
  • MutationApprovalView
  • MutationRequestDecisionView

Resolution

  • IMutationRequestVersionResolver
  • IMutationRequestVersionResolutionManager
  • MutationRequestVersionResolution
  • MutationRequestVersionResolutionOutcome
  • VersionedRequestResolutionStrategy

Execution

  • IGovernanceExecutionManager
  • GovernanceExecutionManager
  • GovernedExecutionResult<TState>

Package structure

The project is organized by governance concern:

  • Abstractions/Requests for request models, decisions, and factory methods
  • Abstractions/Storage for persistence contracts
  • Abstractions/Approval for approval requirements and workflow contracts
  • Abstractions/Resolution for stale-version handling and resolution outcomes
  • Abstractions/Execution for governed execution contracts and results
  • Runtime for lifecycle, approval, resolution, execution, and in-memory storage services
  • Abstractions/Exceptions for governance-specific failures

Examples

Runnable examples live under Examples/Governance:

Relationship to the core package

ModularityKit.Mutator owns mutation execution, policy evaluation, audit, history, side effects, and metrics.

ModularityKit.Mutator.Governance owns the request lifecycle around that execution: approvals, pending states, request storage, stale-version resolution, and terminal governance decisions.

It also owns the query-oriented read side for governed requests, approval work, and decision history.

Current scope

Included today:

  • request modeling and decision history
  • approval requirements and workflow execution
  • optimistic concurrency in request storage
  • version-aware resolution before execution
  • governed execution orchestration
  • in-memory support for local runtime scenarios

Not included yet:

  • production persistence providers such as EF Core or PostgreSQL
  • reporting/query stores for operational governance views
  • compensation or retry orchestration
  • external approval system integrations
Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (1)

Showing the top 1 NuGet packages that depend on ModularityKit.Mutator.Governance:

Package Downloads
ModularityKit.Mutator.Governance.Redis

Redis provider for ModularityKit.Mutator.Governance.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.7.0 146 7/4/2026
1.6.0 144 6/29/2026
1.5.0 135 6/26/2026
0.1.4 113 6/24/2026
0.1.3 112 6/24/2026