chore: enable digest without creating its config row by hand - #1425
Conversation
Time Submission Status
Submit or update total time with: Add time on top of previous submission with: See available commands to help comply with our Guidelines. |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Team Run ID: 📒 Files selected for processing (4)
Included review availability: Your plan provides up to 1 included review per hour; 0 remain after this review. 📝 WalkthroughWalkthroughMigration 019 now seeds the singleton ChangesDigest configuration seeding
Estimated code review effort: 2 (Simple) | ~10 minutes Merge Risk: ⚪ Minimal · up to This change provides a disabled default digest configuration for new deployments without altering existing configurations, with coverage for the seeded values. No merge-blocking risk is identified. 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches 💡 1🛠️ Fix failing CI checks 💡
📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
@holdex pr submit-time 4h |
digest_confighas never had its row created by a migration. The table shipsempty, the scheduler reads that as "disabled" and stops, and in the logs that is
indistinguishable from digest having been switched off deliberately. On testnet
it went unnoticed until the pending-day queue had been filling since 2010.
019 now seeds the row, disabled:
Digest starts nowhere new.
ON CONFLICT DO NOTHINGleaves a network that alreadyhas a row exactly as it was, schedule included, so an existing deployment keeps
its own cadence. Enabling digest stays an operator decision made through a signed
exec-sql. What changes is that the operator now runs anUPDATE, rather thanfirst having to work out that the row was missing at all.
digest_scheduleisNOT NULLwith no default, which is why this row cannot beconjured from column defaults the way
duplicate_prune_config's is in 056. Theseeded value matches
DefaultDigestScheduleinextensions/tn_digest/constants.go, the fallback the extension already applieswhen the schedule comes back empty, so the two no longer differ by accident.
Tests
testDigestConfigShipsSeededasserts the row exists, is disabled, and that itsschedule still equals that constant, so drift in either direction fails instead
of quietly changing a fresh network's cadence.
go test -tags kwiltest ./tests/streams/digest/ -run TestDigestActions -count=1passes in 781s.
Also
Two comments claimed
digest_configis not seeded, one in 056 and one in theprune test. This makes both false, so they are corrected.
Summary by CodeRabbit
New Features
Tests