Files
buzz/scripts
Elrond 7d21362bb9 buzz-db: check events created_at floor in the app writers (phase 1)
Every channel-bearing INSERT INTO events now checks created_at against
database clock_timestamp() minus CREATED_AT_FLOOR_SECS on the admitted
transaction before inserting, and returns the typed, non-retryable
DbError::CreatedAtFloorRejected. The check samples the clock after BEGIN,
so the replica-fence wall min(oldest_xact_start, S) - floor - margin
still covers it. Migration 0021's deferred trigger and the writer-pool
GUC stay in place as the mixed-version backstop until phase 2.

A source policy requires the check on every channel-bearing events
INSERT and forbids production UPDATEs of events.created_at/channel_id.
The admin seed script now refuses non-local PGHOST.

Refs BUZZ-316.

Signed-off-by: Elrond <28d6302a099e5225b02c4155ac4236e4912603df2ab08dbfc2f4fef08ce598c8@buzz.block.builderlab.xyz>
2026-10-14 13:50:01 -04:00
..