Skip to content

perf: load documents with authors in the active drafts index - #11902

Merged
jennifer-richards merged 1 commit into
ietf-tools:mainfrom
rjsparks:active-draft-index-opt
Oct 16, 2026
Merged

jennifer-richards merged 1 commit into
ietf-tools:mainfrom
rjsparks:active-draft-index-opt

Conversation

@rjsparks

Copy link
Copy Markdown
Member

active_drafts_index_by_group() read a.document.name for each DocumentAuthor row but joined only person, so each author ran its own document query: more than 1,400 per build of /doc/active/ and id-index.txt. Join document as well, so the authors loop runs a single query.

Add a test that checks the query count stays the same as active drafts and authors are added.

active_drafts_index_by_group() read a.document.name for each
DocumentAuthor row but joined only person, so each author ran its
own document query: more than 1,400 per build of /doc/active/ and
id-index.txt. Join document as well, so the authors loop runs a
single query.

Add a test that checks the query count stays the same as active
drafts and authors are added.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@codecov

codecov Bot commented Oct 16, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 89.02%. Comparing base (409fdf3) to head (98210af).
⚠️ Report is 2 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main   #11902   +/-   ##
=======================================
  Coverage   89.02%   89.02%           
=======================================
  Files         342      342           
  Lines       46539    46539           
=======================================
  Hits        41433    41433           
  Misses       5106     5106           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.
@jennifer-richards
jennifer-richards merged commit 2067453 into ietf-tools:main Oct 16, 2026
@github-actions github-actions Bot locked as resolved and limited conversation to collaborators Oct 20, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

2 participants