mirror of
https://github.com/MeshCore-Beacon/beacon-server.git
synced 2026-12-06 15:34:26 +00:00
* feat(planguard): read sqlc statement text and load a strict plan corpus * fix(planguard): fail on unextracted statements, keep fragments mode-neutral * feat(planguard): plan assertions, scoped sort exemptions and narrow retired-index verdicts * fix(planguard): an errored run always fails * fix(planguard): keep subplan conds off their parent scan; fail on unanalyzed budgets * feat(planguard): read-only plan runner, reports and the run command * fix(planguard): validate identifiers in emitted scripts; prove read-only runs * feat(planguard): end-state corpus, planted regressions and the generated cached-plan policy * fix(planguard): derive observer cases from data; mark legacy generic plans * fix(planguard): bound the dense-region route resolvers; test policy refusals * fix(planguard): re-measure the dense-region route cases; cover every policy refusal * feat(planguard): synthetic fixture built through the migrations, checked in CI * ci(planguard): build the fixture once; guard fixture data for identifiers * fix(planguard): hash every fixture generator input; harden the fixture guard * feat(planguard): snapshot diff over every column, named result classes and cursor walks * fix(planguard): bound the relaxed diff classes; derive the cursor tie from data * fix(planguard): refuse multi-statement text in the corpus runner * feat: read-only server mode and an HTTP page diff between two builds * fix(planguard): refuse escape strings and psql meta-commands in corpus text * fix: storediff follows each build's own cursor; prove read-only gates via the log * fix(planguard): match the PostgreSQL lexer on high-bit bytes; check every emitted line * feat(admin): daily read-only plan check on the maintenance pool, its metric and report * feat(planguard): daily prod check behind planguard.daily_check * fix(planguard): cancel fresh runs at shutdown; expose a never-ran check * ci(planguard): pin the fixture server and collation; refresh baselines * fix(planguard): calibrate route budgets on one dataset; skip entries whose index is absent
240 lines
6.7 KiB
JSON
240 lines
6.7 KiB
JSON
[
|
|
{
|
|
"Plan": {
|
|
"Node Type": "Sort",
|
|
"Parallel Aware": false,
|
|
"Total Cost": 3907.53,
|
|
"Plan Rows": 51,
|
|
"Actual Rows": 51,
|
|
"Actual Loops": 1,
|
|
"Sort Key": [
|
|
"pg.k DESC",
|
|
"p.packet_hash DESC"
|
|
],
|
|
"Shared Hit Blocks": 760,
|
|
"Shared Read Blocks": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Limit",
|
|
"Parent Relationship": "InitPlan",
|
|
"Subplan Name": "CTE page",
|
|
"Parallel Aware": false,
|
|
"Total Cost": 1.6,
|
|
"Plan Rows": 51,
|
|
"Actual Rows": 51,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 5,
|
|
"Shared Read Blocks": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Index Only Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Scan Direction": "Forward",
|
|
"Index Name": "idx_packets_last_heard_hash",
|
|
"Relation Name": "packets",
|
|
"Alias": "p_1",
|
|
"Total Cost": 69933.35,
|
|
"Plan Rows": 3048658,
|
|
"Actual Rows": 51,
|
|
"Actual Loops": 1,
|
|
"Index Cond": "(ROW(last_heard_at, packet_hash) < ROW('infinity'::timestamp with time zone, '\\x'::bytea))",
|
|
"Shared Hit Blocks": 5,
|
|
"Shared Read Blocks": 0
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"Node Type": "Nested Loop",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Join Type": "Left",
|
|
"Total Cost": 3904.36,
|
|
"Plan Rows": 51,
|
|
"Actual Rows": 51,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 760,
|
|
"Shared Read Blocks": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Nested Loop",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Join Type": "Left",
|
|
"Total Cost": 3885.62,
|
|
"Plan Rows": 51,
|
|
"Actual Rows": 51,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 748,
|
|
"Shared Read Blocks": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Nested Loop",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Join Type": "Left",
|
|
"Total Cost": 3879.39,
|
|
"Plan Rows": 51,
|
|
"Actual Rows": 51,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 622,
|
|
"Shared Read Blocks": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Nested Loop",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Join Type": "Inner",
|
|
"Total Cost": 136.04,
|
|
"Plan Rows": 51,
|
|
"Actual Rows": 51,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 209,
|
|
"Shared Read Blocks": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "CTE Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"CTE Name": "page",
|
|
"Alias": "pg",
|
|
"Total Cost": 1.02,
|
|
"Plan Rows": 51,
|
|
"Actual Rows": 51,
|
|
"Actual Loops": 1,
|
|
"Shared Hit Blocks": 5,
|
|
"Shared Read Blocks": 0
|
|
},
|
|
{
|
|
"Node Type": "Index Scan",
|
|
"Parent Relationship": "Inner",
|
|
"Parallel Aware": false,
|
|
"Scan Direction": "Forward",
|
|
"Index Name": "packets_pkey",
|
|
"Relation Name": "packets",
|
|
"Alias": "p",
|
|
"Total Cost": 2.65,
|
|
"Plan Rows": 1,
|
|
"Actual Rows": 1,
|
|
"Actual Loops": 51,
|
|
"Index Cond": "(packet_hash = pg.packet_hash)",
|
|
"Shared Hit Blocks": 204,
|
|
"Shared Read Blocks": 0
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"Node Type": "Limit",
|
|
"Parent Relationship": "Inner",
|
|
"Parallel Aware": false,
|
|
"Total Cost": 73.38,
|
|
"Plan Rows": 1,
|
|
"Actual Rows": 1,
|
|
"Actual Loops": 51,
|
|
"Shared Hit Blocks": 413,
|
|
"Shared Read Blocks": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Sort",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Total Cost": 73.54,
|
|
"Plan Rows": 64,
|
|
"Actual Rows": 1,
|
|
"Actual Loops": 51,
|
|
"Sort Key": [
|
|
"packet_observations.heard_at DESC",
|
|
"packet_observations.id DESC"
|
|
],
|
|
"Shared Hit Blocks": 413,
|
|
"Shared Read Blocks": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Index Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Scan Direction": "Forward",
|
|
"Index Name": "idx_observations_packet",
|
|
"Relation Name": "packet_observations",
|
|
"Alias": "packet_observations",
|
|
"Total Cost": 73.06,
|
|
"Plan Rows": 64,
|
|
"Actual Rows": 8,
|
|
"Actual Loops": 51,
|
|
"Index Cond": "(packet_hash = p.packet_hash)",
|
|
"Shared Hit Blocks": 413,
|
|
"Shared Read Blocks": 0
|
|
}
|
|
]
|
|
}
|
|
]
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"Node Type": "Memoize",
|
|
"Parent Relationship": "Inner",
|
|
"Parallel Aware": false,
|
|
"Total Cost": 2.51,
|
|
"Plan Rows": 1,
|
|
"Actual Rows": 1,
|
|
"Actual Loops": 51,
|
|
"Cache Key": "packet_observations.observer_id",
|
|
"Cache Mode": "logical",
|
|
"Cache Hits": 9,
|
|
"Cache Misses": 42,
|
|
"Cache Evictions": 0,
|
|
"Cache Overflows": 0,
|
|
"Peak Memory Usage": 6,
|
|
"Shared Hit Blocks": 126,
|
|
"Shared Read Blocks": 0,
|
|
"Plans": [
|
|
{
|
|
"Node Type": "Index Scan",
|
|
"Parent Relationship": "Outer",
|
|
"Parallel Aware": false,
|
|
"Scan Direction": "Forward",
|
|
"Index Name": "observers_pkey",
|
|
"Relation Name": "observers",
|
|
"Alias": "o",
|
|
"Total Cost": 2.5,
|
|
"Plan Rows": 1,
|
|
"Actual Rows": 1,
|
|
"Actual Loops": 42,
|
|
"Index Cond": "(id = packet_observations.observer_id)",
|
|
"Shared Hit Blocks": 126,
|
|
"Shared Read Blocks": 0
|
|
}
|
|
]
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"Node Type": "Index Scan",
|
|
"Parent Relationship": "Inner",
|
|
"Parallel Aware": false,
|
|
"Scan Direction": "Forward",
|
|
"Index Name": "transport_scopes_pkey",
|
|
"Relation Name": "transport_scopes",
|
|
"Alias": "ts",
|
|
"Total Cost": 0.3,
|
|
"Plan Rows": 1,
|
|
"Actual Rows": 0,
|
|
"Actual Loops": 51,
|
|
"Index Cond": "(id = p.scope_id)",
|
|
"Shared Hit Blocks": 12,
|
|
"Shared Read Blocks": 0
|
|
}
|
|
]
|
|
}
|
|
]
|
|
},
|
|
"Planning": {
|
|
"Shared Hit Blocks": 19,
|
|
"Shared Read Blocks": 0
|
|
},
|
|
"Planning Time": 0.211,
|
|
"Execution Time": 0.328
|
|
}
|
|
]
|