refactor code

This commit is contained in:
Матвей
2026-11-06 11:12:38 +03:00
parent c885462c04
commit 7fe48e38c1
50 changed files with 5674 additions and 564 deletions
+11
View File
@@ -0,0 +1,11 @@
-- A separate immutable cohort: replay and job cleanup must not rewrite SLO history.
-- Existing jobs have no recoverable acceptance commit and are deliberately not backfilled.
CREATE TABLE attachment_slo (
attachment_id uuid PRIMARY KEY,
accepted_xid xid NOT NULL DEFAULT pg_current_xact_id()::xid,
ready_xid xid,
accepted_at timestamptz,
ready_at timestamptz,
bad boolean
);
CREATE INDEX attachment_slo_unresolved_idx ON attachment_slo(accepted_at) WHERE bad IS NULL;