I think I've found a bug in the SQLite storage backend for Durable Objects. When I call deleteAll() from an alarm handler, it causes an internal error. Which means the alarm handler fails and keeps getting retried.
However, if I do await this.ctx.storage.deleteAlarm(); before calling deleteAll(), it works fine.
(I'm using this as a workaround with no problem. But it seems like a bug.)
Use case: I want to use alarms to delete all data, for eg a verify link that auto-expires.
FWIW this problem didn't seem to happen when I was using the KV storage backend.
I think I've found a bug in the SQLite storage backend for Durable Objects. When I call
deleteAll()
from an alarm handler, it causes an internal error. Which means the alarm handler fails and keeps getting retried.However, if I do
await this.ctx.storage.deleteAlarm();
before callingdeleteAll()
, it works fine.(I'm using this as a workaround with no problem. But it seems like a bug.)
Use case: I want to use alarms to delete all data, for eg a verify link that auto-expires.
FWIW this problem didn't seem to happen when I was using the KV storage backend.