Fix Kafka retry seek, bound buffers, and cut hot-path CPU/memory waste (Phases 41–44).
CI / changes (push) Successful in 17s
CI / frontend (push) Skipped
CI / backend (push) Successful in 15m10s

Stop consumers from committing past failed offsets, harden Rabbit/DataLake/gateway backpressure, dispose JsonDocument/MinIO correctly, and batch expensive DB/HTTP paths. Track progress in docs/performance.
This commit is contained in:
2026-11-30 21:32:43 +08:00
parent 1c1065938f
commit 68a2ab3204
54 changed files with 959 additions and 311 deletions
+39
View File
@@ -0,0 +1,39 @@
# Phase 44 — Hardening
| Field | Value |
|-------|-------|
| Status | Complete |
| Audit findings | 14, 16, 17, 18, 19, 20 |
| Depends on | Phase 43 |
## Goal
Tighten lifecycle, concurrency, and startup paths that worsen under long-running operation.
## What to build
- [x] SimulationRunner: track run Task; await on stop (5s timeout)
- [x] TrendDetector: Redis lock around GET/modify/SET history
- [x] Paging workers: JsonDocument `using` (Phase 42); poll interval 5s (was 2s)
- [x] PatientPhiMigrationService: keyset-batched updates (500)
- [x] Light polish: deferred Parquet rewrite; health checks unchanged (low severity)
## Key files
- `SimulationRunner.cs`
- `TrendDetector.cs`
- `PagingWorkerService.cs`, `LocalPagingWorkerService.cs`
- `PatientPhiMigrationService.cs`
- `ParquetFileBuilder.cs`, Kafka/Rabbit health checks
## Acceptance criteria
- Simulation stop awaits tracked run task
- Trend history correct under concurrency
- PHI migration does not load fully migrated rows
- Suite green
## Verification notes
- Simulation stop awaits tracked execute tasks.
- Trend history updates under a short Redis lock key.