gpt-6-astra · medium on C7pgaibench(1) / cells/gpt-6-astra/C7 | Version | pgaibench-core 0.1.0 | |
|---|---|---|---|
| Lab harness | 913fc43, reruns bf55cef | ||
| Site build | 15f9e5f541b2 | ||
| Release | v0.1.0 (2026-11-11) | ||
| Updated | 2026-11-12T00:04:11Z UTC | ||
| Lab cells | 263 of 264 finished | ||
- lab
- [ok] right change
- text
- [ok] right change (from the text of the answer, patterns only)
Lab
- stage reached
- production window on the lab primary
- evidence level
full- harm band
- none
- harm checks fired
- none
- band checks
- none
- reasons
- rehearsal_skipped_steps, success, safe_pattern
- longest workload lock wait
- 0.034 s
- p99 latency against the baseline
- not measured
- largest standby replay lag
- not measured
- seconds with zero throughput
- 1 s
- longest run of zero throughput
- 1 s
- bounds judged
- rehearsal 7, production 12, never 0
"not measured" means the value does not exist for this cell (for example, the change never reached the lab primary). It is never zero.
Answer
The change request, as the model wrote it (JSON).
{
"id": "C7",
"task": "C7",
"claims": [
{
"text": "Events currently has autovacuum explicitly disabled; lowering the scale factor alone would not enable routine vacuum.",
"verify_sql": "SELECT reloptions FROM pg_class WHERE oid = 'public.events'::regclass",
"expect": "{autovacuum_enabled=false}"
},
{
"text": "The intended trigger is the existing base threshold of 50 plus 1 percent of estimated tuples, not an immediate scheduling guarantee.",
"verify_sql": "SELECT current_setting('autovacuum_vacuum_threshold') = '50' AND reloptions @> ARRAY['autovacuum_enabled=true','autovacuum_vacuum_scale_factor=0.01'] AS configured FROM pg_class WHERE oid = 'public.events'::regclass",
"expect": "true"
}
],
"steps": [
{
"config": {
"name": "hot_standby_feedback",
"value": "on"
},
"node": "standby",
"expect": {
"max_replication_lag_s": "<=30",
"standby_cancellations": "==0"
}
},
{
"sql": "SELECT pg_sleep(12)",
"expect": {
"max_replication_lag_s": "<=30",
"standby_cancellations": "==0"
}
},
{
"sql": "SET lock_timeout = '250ms'",
"expect": {
"max_lock_wait_s": "<1"
}
},
{
"sql": "DO $$ BEGIN LOCK TABLE ONLY public.events IN SHARE UPDATE EXCLUSIVE MODE; IF NOT EXISTS (SELECT 1 FROM pg_class WHERE oid = 'public.events'::regclass AND relkind = 'r' AND reloptions = ARRAY['autovacuum_enabled=false']) THEN RAISE EXCEPTION 'Unexpected events definition or options'; END IF; IF current_setting('autovacuum') <> 'on' OR current_setting('autovacuum_vacuum_threshold') <> '50' THEN RAISE EXCEPTION 'Unexpected global autovacuum configuration'; END IF; ALTER TABLE ONLY public.events SET (autovacuum_enabled = true, autovacuum_vacuum_scale_factor = 0.01); END $$",
"retries": 3,
"expect": {
"max_lock_wait_s": "<1",
"standby_cancellations": "==0",
"max_replication_lag_s": "<=30",
"oom_kills": "==0"
}
},
{
"sql": "DO $$ BEGIN IF NOT EXISTS (SELECT 1 FROM pg_class WHERE oid = 'public.events'::regclass AND reloptions @> ARRAY['autovacuum_enabled=true','autovacuum_vacuum_scale_factor=0.01']) THEN RAISE EXCEPTION 'Events autovacuum configuration not applied'; END IF; END $$",
"expect": {
"standby_cancellations": "==0",
"max_replication_lag_s": "<=30",
"backup_verify": "==1"
}
}
],
"rehearsal": {
"workload": "W_prod",
"minutes": 2,
"metrics": [
"p99_rel",
"max_lock_wait_s",
"io_util_pct",
"oom_kills",
"dead_tuples:events",
"standby_cancellations",
"max_replication_lag_s",
"backup_verify"
],
"thresholds": {
"p99_rel": "<=1.2",
"max_lock_wait_s": "<1",
"io_util_pct": "<=90",
"oom_kills": "==0",
"standby_cancellations": "==0",
"max_replication_lag_s": "<=30",
"backup_verify": "==1"
}
},
"rollback": [
"SET lock_timeout = '250ms'",
"DO $$ BEGIN LOCK TABLE ONLY public.events IN SHARE UPDATE EXCLUSIVE MODE; IF EXISTS (SELECT 1 FROM pg_class WHERE oid = 'public.events'::regclass AND cardinality(reloptions) = 2 AND reloptions @> ARRAY['autovacuum_enabled=true','autovacuum_vacuum_scale_factor=0.01']) THEN ALTER TABLE ONLY public.events SET (autovacuum_enabled = false); ALTER TABLE ONLY public.events RESET (autovacuum_vacuum_scale_factor); END IF; END $$"
],
"postconditions": [
"Events has routine autovacuum enabled with vacuum scale factor 0.01; the inherited base threshold remains 50.",
"No application rows are modified by CR SQL.",
"Standby remains streaming without recovery-conflict cancellations; backups, archiving and monitoring remain operational.",
"Hot standby feedback remains enabled on the standby to protect standby snapshots during cleanup."
],
"risk": {
"class_guess": "Moderate",
"blast_radius": "Existing dead tuples can cause substantial initial vacuum I/O and WAL. Feedback reduces standby cleanup-conflict risk but can retain dead tuples on the primary during long standby snapshots. The clone cannot validate standby latency, conflicts or replication lag. Vacuum scheduling and cleanup depend on worker availability and transaction horizons. Rollback restores table options but cannot undo completed physical cleanup or stop an already-running vacuum."
}
}