Skip to content

fix(reconciler): parameterize circuit breaker SQL query#1999

Merged
jrf0110 merged 2 commits intoconvoy/fix-reconciler-p0-p1-bug-fixes-from-audi/f071bd6c/headfrom
convoy/fix-reconciler-p0-p1-bug-fixes-from-audi/f071bd6c/gt/toast/098c4d8f
Apr 4, 2026
Merged

fix(reconciler): parameterize circuit breaker SQL query#1999
jrf0110 merged 2 commits intoconvoy/fix-reconciler-p0-p1-bug-fixes-from-audi/f071bd6c/headfrom
convoy/fix-reconciler-p0-p1-bug-fixes-from-audi/f071bd6c/gt/toast/098c4d8f

Conversation

@jrf0110
Copy link
Copy Markdown
Contributor

@jrf0110 jrf0110 commented Apr 4, 2026

Summary

Replaced template literal interpolation in the circuit breaker SQL query (strftime('...', 'now', '-${CIRCUIT_BREAKER_WINDOW_MINUTES} minutes')) with a JS-computed ISO 8601 cutoff timestamp passed as a bound SQL parameter. This eliminates string interpolation inside the SQL string while preserving the same 30-minute window behavior. No functional change.

Verification

  • Typecheck passes (reported by polecat)
  • All 15 reconciler integration tests pass (1 pre-existing failure in Rule 6 test is unrelated)

Visual Changes

N/A

Reviewer Notes

  • The branch includes an empty WIP: container eviction save commit with no file changes — can be squashed on merge.
  • The change aligns with the codebase convention of using ? bound parameters with the query() helper instead of interpolating values into SQL strings.

John Fawcett added 2 commits April 4, 2026 15:01
Replace strftime template literal interpolation with a JS-computed
cutoff timestamp passed as a bound SQL parameter. Same 30-minute
window, no behavioral change.
@kilo-code-bot
Copy link
Copy Markdown
Contributor

kilo-code-bot bot commented Apr 4, 2026

Code Review Summary

Status: No Issues Found | Recommendation: Merge

Files Reviewed (1 files)
  • cloudflare-gastown/src/dos/town/reconciler.ts

Reviewed by gpt-5.4-20260305 · 335,583 tokens

@jrf0110 jrf0110 merged commit 6c72827 into convoy/fix-reconciler-p0-p1-bug-fixes-from-audi/f071bd6c/head Apr 4, 2026
2 checks passed
@jrf0110 jrf0110 deleted the convoy/fix-reconciler-p0-p1-bug-fixes-from-audi/f071bd6c/gt/toast/098c4d8f branch April 4, 2026 20:24
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