Skip to content

Reduce historical run scans in job reads - #341

Merged
exe-dev-github-integration[bot] merged 1 commit into
mainfrom
gen-2812-reduce-history-scans
Nov 10, 2026
Merged

exe-dev-github-integration[bot] merged 1 commit into
mainfrom
gen-2812-reduce-history-scans

Conversation

@asselstine

Copy link
Copy Markdown
Collaborator

Summary

  • Replace full-history latest-state aggregation with indexed latest-row lookups and active-only counts.
  • Restrict run duration enrichment to the returned page and distinct active jobs; terminal durations use their own timestamps.
  • Add history and active-run indexes with PostgreSQL coverage for ties, tenants, pagination, and duration semantics.

Validation

  • Targeted PostgreSQL tests passed.
  • npm test ran; backend suite had timeout failures in unrelated authentication/setup tests, and app browser unit suite had two unrelated failures under load. Functional browser checks passed.
  • Before/after EXPLAIN measurements are recorded in ~/.factorize-job/gen2812-measurements.md. Job summary: 9.286 ms / 1062 shared hits to 0.195 ms / 13; full statistics: 98.622 ms / 533 to 0.147 ms / 7. Run-list range remains dominant (83.306 ms / 624 vs 99.306 ms / 630); no run-list speedup claimed.

@linear

linear Bot commented Nov 10, 2026

Copy link
Copy Markdown

GEN-2812

@asselstine
asselstine force-pushed the gen-2812-reduce-history-scans branch from 1ece222 to 7004f2a Compare November 10, 2026 23:46
@asselstine
asselstine force-pushed the gen-2812-reduce-history-scans branch from 7004f2a to 0454bdc Compare November 10, 2026 23:48
@exe-dev-github-integration
exe-dev-github-integration Bot merged commit d5bb057 into main Nov 10, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant