billflare.

The immortal alarm: a Durable Object alarm that rescheduled itself forever

Bounded’s founder describes a self-rescheduling Durable Object alarm whose row writes grew with the number of objects ever created, why the in-app meter missed it, and the rule that fixed it.

Products
Durable Objects
Source
Author experienceBounded blog
Author
Amit Ishairzay

Key points

  • Every realtime object armed a 5-second alarm on first touch and the handler rescheduled unconditionally, so every app and room ever created, including test apps, kept waking 17,280 times a day. The author notes setAlarm is itself a billed row write.
  • Warning sign he names: growth proportional to object count rather than requests, and a steady write pattern on objects serving no external traffic. His usage counters only measured app activity and missed the system writes Cloudflare billed.
  • Fix: re-arm only when real work is pending, use exact-time wakes instead of 5-second polling, park empty rooms after a grace period, buffer the meter in memory, and delete zombie staging workers. He reports rows written per 5 minutes dropping from about 328,000 to 141–214.
  • Official Durable Objects pricing (rechecked 2026-10-14) confirms each setAlarm() is billed as one row written on SQLite storage.

Original sources

  1. Published

    The immortal alarm: a Durable Object alarm that rescheduled itself forever

    Open original source

    Bounded’s founder describes a self-rescheduling Durable Object alarm whose row writes grew with the number of objects ever created, why the in-app meter missed it, and the rule that fixed it.

Author experienceDurable Objects +3

Designing a poker game on Durable Objects so idle time costs nothing

Philip Atkinson describes the architecture of his multiplayer poker game on the Cloudflare Developer Platform and the cost rules he follows: archive finished games out of Durable Object storage, hibernate WebSockets, wake with alarms and treat logging as a cost decision.

D1

A missing index on a D1 DELETE read about 4 trillion rows, a $4,114.97 charge.

Community user user11226 says a missing database index made a DELETE operation repeatedly scan the table, generating about 4.03 trillion D1 rows read in the billing period and an unexpected $4,114.97 bill on what they understood to be a $5-a-month subscription. In follow-ups they accept they should have configured billing alerts, say Cloudflare successfully challenged their chargeback while the urgent billing case took more than three weeks to get a response, and ask for someone to review the circumstances.

Author experienceWorkers +7

Lanshu: an AI-assisted Cloudflare billing risk checklist

Lanshu (@LufzzLiz) shares a six-step prompt for checking account ownership, usage, runaway consumption and budget alerts. Replies add alarm logging, email delivery checks and separate notifications.