|
- namespace Campaign_Tracker.Server.ExtensionData;
-
- /// <summary>
- /// Result of a nightly (or on-demand) extension-to-legacy referential integrity check (AC #4).
- /// Targeting at least 99.9% <see cref="ConsistencyPercentage"/> (NFR13).
- /// </summary>
- public sealed record LegacyLinkIntegrityReport(
- DateTimeOffset CheckedAt,
- int ProviderCount,
- int TotalRecords,
- int ConsistentRecords,
- int FailedRecords,
- double ConsistencyPercentage,
- IReadOnlyList<LegacyLinkIntegrityFailure> Failures)
- {
- /// <summary>True when no failures were detected (or no records exist to check).</summary>
- public bool IsConsistent => ProviderCount > 0 && FailedRecords == 0;
- }
-
- /// <summary>Describes one extension record that failed to resolve its legacy link.</summary>
- public sealed record LegacyLinkIntegrityFailure(
- string RecordType,
- string RecordId,
- LegacyLinkReference Reference,
- string Reason);
|