Skip to main content

Posts

Featured

New ask Hacker News story: Durable Object alarm loop: $34k in 8 days, zero users, no platform warning

Durable Object alarm loop: $34k in 8 days, zero users, no platform warning 9 by thewillmoss | 0 comments on Hacker News. Sharing this as a warning to anyone using Cloudflare Durable Objects with alarms. Root cause: My DO agent's onStart() handler called this.ctx.storage.setAlarm() on every wake-up without checking whether an alarm was already scheduled. Combined with 60+ preview Worker deployments each creating independent DO instances, this created a runaway self-health-check loop. Timeline: - April 3: loop began (zero DO usage before this date) - April 4-5: peaked at ~930 billion row reads/day - April 11: found it, fixed it - April 15: $34,895 invoice due with no billing response yet The fix: // Before (dangerous) async onStart() { await this.ctx.storage.setAlarm(Date.now() + 60_000) } // After (safe) async onStart() { const existing = await this.ctx.storage.getAlarm() if (!existing) { await this.ctx.storage.setAlarm(Date.now() + 60_000) } } Other things worth doing: - Strip D...

Latest Posts

New ask Hacker News story: Ask HN: Is Claude Getting Worse?

New ask Hacker News story: Any engineers here with experience of clinical data standards?

New ask Hacker News story: Is anyone actually using OpenClaw?

New ask Hacker News story: GitHub gave webhook secrets away in webhook call

New ask Hacker News story: Tell HN: Fiverr left customer files public and searchable

New ask Hacker News story: Ask HN: What's your favorite security cam system?

New ask Hacker News story: AI Home Architecture Startup Looking for Back End/ML Infra Engineer

New ask Hacker News story: Why most AI projects feel useless

New ask Hacker News story: Ask HN: What are you using OpenClaw or agents for?

New ask Hacker News story: Ask HN: On autistic spectrum, best way to live?