Table of Contents

Class MultiRegionAuditEvents

Namespace
Excalibur.Compliance
Assembly
Excalibur.Compliance.Abstractions.dll

Factory methods for creating multi-region disaster recovery audit events.

public static class MultiRegionAuditEvents
Inheritance
MultiRegionAuditEvents
Inherited Members

Remarks

Multi-region operations generate audit events for:

  • Failover events (automatic and manual)
  • Failback events
  • RPO threshold breaches
  • Replication status changes

These events support SOC 2 compliance by providing evidence of:

  • CC6.6 - Encryption key availability and recovery
  • CC7.2 - System availability monitoring
  • CC9.1 - Business continuity planning

Methods

FailbackCompleted(string, string, string, string, int, string?)

Creates an audit event for a failback operation.

public static AuditEvent FailbackCompleted(string sourceRegion, string targetRegion, string reason, string actorId, int keysSynchronized, string? correlationId = null)

Parameters

sourceRegion string

The region failing back from (secondary).

targetRegion string

The region failing back to (primary).

reason string

The reason for failback.

actorId string

The actor who initiated the failback.

keysSynchronized int

Number of keys synchronized during failback.

correlationId string

Optional correlation ID for related events.

Returns

AuditEvent

An audit event representing the failback.

FailoverInitiated(string, string, string, bool, string, string?)

Creates an audit event for a failover operation.

public static AuditEvent FailoverInitiated(string sourceRegion, string targetRegion, string reason, bool isAutomatic, string actorId, string? correlationId = null)

Parameters

sourceRegion string

The region failing from (primary).

targetRegion string

The region failing to (secondary).

reason string

The reason for failover.

isAutomatic bool

Whether the failover was triggered automatically.

actorId string

The actor who initiated the failover (for manual) or "System" (for automatic).

correlationId string

Optional correlation ID for related events.

Returns

AuditEvent

An audit event representing the failover.

RegionHealthChanged(string, bool, bool, int, string?, string?)

Creates an audit event for a region health status change.

public static AuditEvent RegionHealthChanged(string regionId, bool previousStatus, bool currentStatus, int consecutiveFailures, string? errorMessage = null, string? correlationId = null)

Parameters

regionId string

The region whose health changed.

previousStatus bool

The previous health status.

currentStatus bool

The current health status.

consecutiveFailures int

Number of consecutive health check failures.

errorMessage string

Error message if unhealthy.

correlationId string

Optional correlation ID for related events.

Returns

AuditEvent

An audit event representing the health status change.

ReplicationSyncCompleted(string, string, int, TimeSpan, string?)

Creates an audit event for a replication sync completion.

public static AuditEvent ReplicationSyncCompleted(string sourceRegion, string targetRegion, int keyCount, TimeSpan duration, string? correlationId = null)

Parameters

sourceRegion string

The source region of the replication.

targetRegion string

The target region of the replication.

keyCount int

Number of keys synchronized.

duration TimeSpan

Duration of the sync operation.

correlationId string

Optional correlation ID for related events.

Returns

AuditEvent

An audit event representing the sync completion.

RpoThresholdBreached(TimeSpan, TimeSpan, string, int, string?)

Creates an audit event for an RPO threshold breach.

public static AuditEvent RpoThresholdBreached(TimeSpan currentLag, TimeSpan threshold, string activeRegion, int pendingKeys, string? correlationId = null)

Parameters

currentLag TimeSpan

The current replication lag.

threshold TimeSpan

The configured RPO threshold.

activeRegion string

The currently active region.

pendingKeys int

Number of keys pending replication.

correlationId string

Optional correlation ID for related events.

Returns

AuditEvent

An audit event representing the RPO threshold breach.