Skip to content

perf: collapse per-pool /api/pools queries into one round trip - #7

Merged
colneech-dev merged 1 commit into
mainfrom
perf/collapse-pools-bundle-query
Nov 23, 2026
Merged

colneech-dev merged 1 commit into
mainfrom
perf/collapse-pools-bundle-query

Conversation

@colneech-dev

Copy link
Copy Markdown
Owner

Summary

Follow-up to #6. Replaces the 5 remaining separate per-pool queries (stats, total paid, block summary, aux summary, top miners) with one GetPoolApiBundleAsync call using Dapper's QueryMultipleAsync — one connection, one network round trip per pool instead of 5. Removes GetPoolBlockSummaryAsync/GetPoolAuxBlockSummaryAsync, which became dead code once nothing else called them.

Test plan

  • dotnet build -c Release --framework net10.0 clean, 0 errors
  • Combined SQL batch verified against live DB, including the zero-blocks edge case
  • Re-time /api/pools against the live server after deploy

🤖 Generated with Claude Code

Replaces the 5 separate cf.Run calls per pool (stats, total paid,
block summary, aux summary, top miners) with one GetPoolApiBundleAsync
call using Dapper's QueryMultipleAsync: one connection checkout, one
network round trip per pool instead of 5. With 12+ pools running
concurrently that was 60 near-simultaneous connection checkouts per
cache-miss request.

Removes GetPoolBlockSummaryAsync/GetPoolAuxBlockSummaryAsync, which
became dead code once nothing called them outside the bundle.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@colneech-dev
colneech-dev merged commit 5839c06 into main Nov 23, 2026
1 check passed
@colneech-dev
colneech-dev deleted the perf/collapse-pools-bundle-query branch November 23, 2026 22:59
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