Cloudflare Durable Objects alarm loop drives US$10,000 bill
和我之前的观点一致 https://t.co/jMInvksgPx 不管用什么云服务一定要注意啊,Vibe Coding 别写出什么死循环了,尤其是用 Durable Objects,要不直接天价...
The billing risk comes from design choices AI code generators routinely make, such as refreshing alarms before expiry, which silently chains invocations forever. Teams deploying on Cloudflare should add alarm-stop rules to agents.md and have a second model review any alarm-renewal logic. Unlike AWS Step Functions, Durable Objects lack a hard spending cap, so cost control depends entirely on the developer's own guardrails.
A developer using AI-assisted vibe coding hit a US$10,000 Cloudflare bill after a Durable Object alarm entered an infinite loop, causing 6 trillion read/write operations.
Sharing the incident, vikingmute notes Durable Objects have no account-level spending cap, only alert emails.Alarms are persistent timers that wake objects and bill per invocation even without requests.
He recommends rules banning alarm setting in constructors and self-renewing chains, requiring explicit termination conditions before any renewal.
和我之前的观点一致 https://t.co/jMInvksgPx 不管用什么云服务一定要注意啊,Vibe Coding 别写出什么死循环了,尤其是用 Durable Objects,要不直接天价...
和我之前的观点一致 x.com/vikingmute/sta… 不管用什么云服务一定要注意啊,Vibe Coding 别写出什么死循环了,尤其是用 Durable Objects,要不直接天价账单了,而且好像它没有价格上限,只能发告警邮件,所以要格外小心。 如果用,可以加一个 规则,同时最好改动要另外一个模型 review,下面是我之前让AI 给我生成的规则,我直接放 agents.md 当中的: Durable Object alarm 是持久定时器,没请求也会唤醒对象,并按次计费。 没有账户级硬顶。 禁止: - 在 constructor 里 setAlarm - 在 alarm() 的每个出口都 setAlarm - 用「快过期就刷新」让一条链永远续上 - 间隔短于 60 秒的自我续订,除非用户明确要求并写明上限 必须: - 没有剩余工作时直接 return,不再 setAlarm - 续订前写清终止条件(次数、截止时间、或存储里的 active 标志) - 测试要覆盖「无工作时 alarm 不再调度」 - 提交说明里写这条链如何停止 浮世绘 @shmily7 遭遇Cloudflare帐单刺客,爆了一万刀的帐单,原因是一个项目 Durable Object alarm 死循环,读写了6万亿次,Viber Codeing误我。 🔗 View Quoted Tweet📊 4 ⚡
This report is categorized under AITOP's "How-to" desk, focusing on US frontier AI labs and Silicon Valley technology leaders. Within our cross-regional analytical framework, it directly maps to AI developer toolchains, coding agents, and engineering workflows. Key entities and technical topics under continuous tracking include Cloudflare, Durable Objects, Vibe Coding, prompt engineering.
Source attribution: curated from Viking (@vikingmute).