Announcing Deno Queues
Deno Queues adds two APIs to Deno KV, `enqueue()` and `listenQueue()`, for offloading or delaying background work with no infrastructure to configure. They are backed by SQLite locally and FoundationDB on Deno Deploy, where V8 isolates spin up on demand to process messages. Delivery is at-least-once, failed handlers retry up to 5 times before the message is dropped, and enqueues can join KV atomic transactions so messages are only sent if the transaction commits. Nonce checks inside those transactions give idempotent processing, and billing is per KV write plus one Deploy request per received message.
Related posts
- Deno KV internals: building a database for the modern web
Deno hardMasterDeno KV's production backend runs on FoundationDB, with a custom "transaction layer" in front of it that handles multi-tenant configuration, JavaScript-native types such as bigint sums, and cross-region replication. To keep latency low, every atomic operation is non-interactive: a single bag of versionstamp checks, set/delete writes and conflict-free mutations that completes in one or two network trips. A sequencer assigns monotonic transaction sequence numbers, and an evaluator turns each batch into a dataflow graph of AND/MUX operations and evaluates it concurrently. Results are reused speculatively before a writer commits them to FoundationDB, which raises throughput without locks.
- Use Deno KV in Node with the new official npm package
Deno mediumAdeptDeno KV is now usable from Node.js through the official @deno/kv npm package, which exposes the same API as Deno's built-in KV through a single openKv function. That function can connect to a managed Deno Deploy database backed by FoundationDB, a self-hosted denokv server, a local SQLite file, or an in-memory store for tests. Most methods are supported, including atomic, enqueue and watch, but listenQueue does not work against remote databases yet. The package targets Node 18+, has no third-party dependencies, ships platform-specific SQLite binaries built with NAPI-RS from the Rust denokv codebase, and stores values in V8's serialization format.
- Announcing Deno KV
Deno mediumAdeptDeno KV is a strongly consistent key-value database built into the Deno runtime. It is backed by SQLite when run locally and by FoundationDB when managed on Deno Deploy, where it is globally replicated across 35 regions. The API stores structured-serializable JavaScript values under array keys, supports prefix listing with cursor pagination, and offers atomic multi-key transactions using check-and-set. Reads are strongly consistent (serializable and linearizable) by default and can opt into eventual consistency for lower latency, for example 7ms versus 94ms in Frankfurt during the beta.
- Announcing self-hosted Deno KV, continuous backups, and replicas
Deno mediumAdeptDeno KV can now be self-hosted via an open-source, MIT-licensed `denokv` binary backed by SQLite and reachable from `Deno.openKv` over KV Connect. Databases hosted on Deno Deploy (backed by FoundationDB) can also stream continuous backups to S3 or GCS, and `denokv --sync-from-s3` runs a read-only local replica from those buckets. The replica keeps full mutation history, so `denokv pitr list` and `pitr checkout` give point-in-time recovery by versionstamp. Self-hosters own backups, replication and HA themselves, and Litestream or LiteFS is recommended for the SQLite file.
- Deno KV vs. Cloudflare Workers KV, Upstash Redis, AWS DynamoDB, and Google Firestore
Deno mediumAdeptA vendor-run benchmark compares Deno KV with Upstash Redis, DynamoDB Global Tables, Google Firestore and Cloudflare Workers KV by timing 10-record reads and writes from colocated serverless functions, with warm-up reads excluded. At p99, Upstash (139ms read) and Deno KV (90ms read, 166ms write) were fastest, while Cloudflare KV was slowest because its caching and eventual consistency make writes take up to 60s to become visible. The comparison also covers each store's consistency and isolation levels, per-million read/write pricing and setup experience. The databases offer different consistency guarantees, so the latency numbers are not strictly like-for-like.