6.4 KiB
6.4 KiB
Audit - StellaOps.Findings.Ledger
Project
- Path:
src/Findings/StellaOps.Findings.Ledger/StellaOps.Findings.Ledger.csproj - Module:
Findings - Kind:
Service - SDK:
Microsoft.NET.Sdk - TargetFramework:
net10.0 - Audit date (UTC): 2026-01-30
Coding Standards Findings
- Status: FAIL
- Nullable: enable
- TreatWarningsAsErrors: explicit true
- Deterministic: inherited true
- 100-line rule violations: 44
- Service locator usage (BuildServiceProvider/GetService): 5
- Analyzer enforcement: missing repo-wide (see summary).
Details
- 100-line files:
src/Findings/StellaOps.Findings.Ledger/Infrastructure/Postgres/PostgresTimeTravelRepository.cs(832 lines)src/Findings/StellaOps.Findings.Ledger/Infrastructure/Postgres/PostgresFindingProjectionRepository.cs(744 lines)src/Findings/StellaOps.Findings.Ledger/Observability/LedgerMetrics.cs(669 lines)src/Findings/StellaOps.Findings.Ledger/Infrastructure/Postgres/PostgresAttestationPointerRepository.cs(668 lines)src/Findings/StellaOps.Findings.Ledger/Services/FindingWorkflowService.cs(568 lines)src/Findings/StellaOps.Findings.Ledger/tools/LedgerReplayHarness/Program.cs(548 lines)src/Findings/StellaOps.Findings.Ledger/Services/AttestationPointerService.cs(474 lines)src/Findings/StellaOps.Findings.Ledger/Domain/DecisionModels.cs(452 lines)src/Findings/StellaOps.Findings.Ledger/Services/SnapshotService.cs(439 lines)src/Findings/StellaOps.Findings.Ledger/Infrastructure/Postgres/PostgresSnapshotRepository.cs(402 lines)src/Findings/StellaOps.Findings.Ledger/Observations/SignalSnapshotBuilder.cs(389 lines)src/Findings/StellaOps.Findings.Ledger/Observability/LedgerTimeline.cs(372 lines)src/Findings/StellaOps.Findings.Ledger/Services/Incident/LedgerIncidentCoordinator.cs(355 lines)src/Findings/StellaOps.Findings.Ledger/Observations/PostgresObservationRepository.cs(342 lines)src/Findings/StellaOps.Findings.Ledger/Services/LedgerEventWriteService.cs(306 lines)src/Findings/StellaOps.Findings.Ledger/tools/LedgerReplayHarness/HarnessDraftParser.cs(303 lines)src/Findings/StellaOps.Findings.Ledger/Domain/SnapshotModels.cs(281 lines)src/Findings/StellaOps.Findings.Ledger/Services/StalenessValidationService.cs(275 lines)src/Findings/StellaOps.Findings.Ledger/Services/LedgerProjectionReducer.cs(257 lines)src/Findings/StellaOps.Findings.Ledger/Infrastructure/Postgres/PostgresLedgerEventRepository.cs(257 lines)src/Findings/StellaOps.Findings.Ledger/Infrastructure/Policy/PolicyEngineEvaluationService.cs(253 lines)src/Findings/StellaOps.Findings.Ledger/Services/ScoredFindingsExportService.cs(238 lines)src/Findings/StellaOps.Findings.Ledger/Options/LedgerServiceOptions.cs(231 lines)src/Findings/StellaOps.Findings.Ledger/Infrastructure/Postgres/PostgresAirgapImportRepository.cs(230 lines)src/Findings/StellaOps.Findings.Ledger/Infrastructure/Attestation/AttestationPointerRecord.cs(227 lines)src/Findings/StellaOps.Findings.Ledger/Services/EvidenceSnapshotService.cs(221 lines)src/Findings/StellaOps.Findings.Ledger/Infrastructure/Projection/LedgerProjectionWorker.cs(205 lines)src/Findings/StellaOps.Findings.Ledger/Infrastructure/Snapshot/ISnapshotRepository.cs(205 lines)src/Findings/StellaOps.Findings.Ledger/Infrastructure/Policy/InlinePolicyEvaluationService.cs(200 lines)src/Findings/StellaOps.Findings.Ledger/Services/ScoredFindingsQueryService.cs(199 lines)src/Findings/StellaOps.Findings.Ledger/Observability/LedgerTelemetry.cs(198 lines)src/Findings/StellaOps.Findings.Ledger/Services/DecisionService.cs(193 lines)src/Findings/StellaOps.Findings.Ledger/Observations/IObservationRepository.cs(187 lines)src/Findings/StellaOps.Findings.Ledger/Services/AlertService.cs(183 lines)src/Findings/StellaOps.Findings.Ledger/Services/AirgapTimelineService.cs(179 lines)src/Findings/StellaOps.Findings.Ledger/Services/ScoringMetricsService.cs(178 lines)src/Findings/StellaOps.Findings.Ledger/Infrastructure/Postgres/RlsValidationService.cs(168 lines)src/Findings/StellaOps.Findings.Ledger/Infrastructure/Merkle/LedgerMerkleAnchorWorker.cs(161 lines)src/Findings/StellaOps.Findings.Ledger/Services/AirgapImportService.cs(157 lines)src/Findings/StellaOps.Findings.Ledger/Infrastructure/Postgres/PostgresOrchestratorExportRepository.cs(146 lines)src/Findings/StellaOps.Findings.Ledger/Infrastructure/Postgres/PostgresLedgerEventStream.cs(130 lines)src/Findings/StellaOps.Findings.Ledger/Infrastructure/Postgres/LedgerDataSource.cs(128 lines)src/Findings/StellaOps.Findings.Ledger/Services/ScoredFindingsQueryModels.cs(128 lines)src/Findings/StellaOps.Findings.Ledger/Hashing/ProjectionHashing.cs(108 lines)
- Service locator matches:
src/Findings/StellaOps.Findings.Ledger/tools/LedgerReplayHarness/Program.cs:95 var writeService = scope.ServiceProvider.GetRequiredService();src/Findings/StellaOps.Findings.Ledger/tools/LedgerReplayHarness/Program.cs:96 var projectionWorker = scope.ServiceProvider.GetRequiredService();src/Findings/StellaOps.Findings.Ledger/tools/LedgerReplayHarness/Program.cs:97 var anchorWorker = scope.ServiceProvider.GetRequiredService();src/Findings/StellaOps.Findings.Ledger/tools/LedgerReplayHarness/Program.cs:98 var logger = scope.ServiceProvider.GetRequiredService().CreateLogger("Harness");src/Findings/StellaOps.Findings.Ledger/tools/LedgerReplayHarness/Program.cs:99 var timeProvider = scope.ServiceProvider.GetRequiredService();
Fix Guidance
- Split files over 100 lines into smaller types or partials.
- Replace service locator usage with constructor injection.
Testing Fullness Findings
- Status: PASS
- Expected layers: Unit
- Detected test projects: src/Findings/__Tests/StellaOps.Findings.Ledger.Tests/StellaOps.Findings.Ledger.Tests.csproj [Unit], src/Findings/__Tests/StellaOps.Findings.Ledger.ReplayHarness.Tests/StellaOps.Findings.Ledger.ReplayHarness.Tests.csproj [Unit], src/Findings/StellaOps.Findings.Ledger.Tests/StellaOps.Findings.Ledger.Tests.csproj [Unit]
- Missing layers: none
Manual checks required
- Observability contract tests for WebService/Worker.
- Offline execution (tests must run without network access).
Fix Guidance
- None.