Skip to content

In development. Expect rough edges and changes. The source code is not public yet.

Deno 8 min read Research mediumAdept

Benchmarking AWS Lambda Cold Starts Across JavaScript Runtimes

Across Express, Fastify and Hono URL-shortener apps deployed to AWS Lambda via Docker and the Lambda Web Adapter, Deno 1.45 showed lower cold-start Init Duration than Node 22 and Bun 1.1, with the Lambda-managed Node runtime included as a reference. Cold starts were forced by changing an environment variable between invocations and measured from CloudWatch. Hyperfine runs on a GCP VM confirmed the gap: Deno started 1.33–1.77x faster, with Hono at about 58 ms versus roughly 100 ms for Node and Bun. The key optimization is to prepopulate Deno's caches (npm/JSR modules, module graph, transpiled TypeScript, V8 code cache) during Docker image build by running the app once with a timeout. Graviton was slower than x86_64 for all runtimes, and the benchmark comes from Deno's own team.

Related posts

  • Deno 1.43: Improved Language Server performance

    Deno mediumAdept

    Deno 1.43 cuts Language Server auto-completion latency in large codebases from 6-8 seconds to under one second and sharply reduces LSP memory use, fixing out-of-memory failures. It reworks node:vm and node:worker_threads for better npm compatibility with tools like Vitest, Docusaurus, Angular CLI and Next.js. It also adds V8 bytecode caching for 5-240% faster startup, a declarative `deno serve` subcommand, a `Deno.serve()` completion promise and `addr` property, JSX precompile skip options, `URL.parse()`, V8 12.4 with Float16Array, and Deno 2 breaking changes behind `DENO_FUTURE=1`.

  • Deno 1.25 Release Notes

    Deno mediumAdept

    Deno 1.25 adds a `deno init` scaffolding command, experimental `npm:` specifiers that run npm packages and binaries without `npm install` or node_modules, and an experimental `Deno.serve()` HTTP/1.1 server benchmarked at 4x Node.js and 3x the previous Deno server on hello-world requests. Startup is faster because dependency analysis is now cached per file, cutting a ts_morph example from ~1080ms to ~225ms on runs after the first. FFI fast calls now cover u64, i64, pointer and a new `buffer` type for TypedArrays, which takes a hash benchmark from ~181ns to ~56ns per call, and `UnsafePointerView` gains getCString, getArrayBuffer and copyInto.

  • Deno 2.9

    Deno mediumAdept

    Deno 2.9 introduces experimental `deno desktop`, which compiles a web UI plus Deno logic into a single native binary using either the OS webview or bundled Chromium via CEF, with native window, tray and dock APIs and cross-compilation to installers for all five targets. `deno install` now seeds `deno.lock` from npm, pnpm, yarn and Bun lockfiles with exact versions and hashes, migrates pnpm workspace config, and shims `node` for tools that shell out to it. Cold start drops from 34ms to 17ms through lazy-loaded Node globals, V8 code caching and a minified snapshot. A new Rust HTTP/1.1 path raises `Deno.serve` throughput 11–27% and cuts peak RSS by 2.2–3.1x. The release also adds CSS module imports, `deno link`/`deno list`, JSR packages in node_modules and automatic lockfile merge-conflict resolution.

  • How immutable scripts in Deno allow Windmill.dev (YC S22) to build production-grade ops

    Deno easyNovice

    Windmill.dev, an open-source platform for building internal workflows and UIs from scripts, runs TypeScript on Deno because inline, version-pinned imports make each script a self-contained, reproducible file that is hashed immutably and stored in Postgres. Deno's opt-in permission model isolates untrusted code in a multi-tenant setting with less overhead than the NSJail sandboxing used for other languages. Dependency caching synced across workers via S3 gives roughly 15ms cold starts and about 30ms end-to-end runs for lightweight scripts, and the team plans to run Deno in-process to approach Lambda-level performance.

  • Deno 1.20 Release Notes

    Deno mediumAdept

    Deno 1.20 cuts JavaScript-to-Rust op call overhead by up to ~60% by using Rust proc macros to generate a dedicated V8 binding per op, eliminating op routing and skipping deserialization of unused arguments; a 1 MB base64 roundtrip drops from ~125 ms to ~3.3 ms. The release also adds automatic gzip/brotli compression of non-streamed HTTP responses, an unstable `deno bench` subcommand (1000 warmup plus 1000 measured iterations by default), and a cross-platform `deno task` runner using a POSIX-like shell subset. Other changes include import maps in the config file, in-memory TLS certs, `Deno.upgradeHttp()`, FFI global statics, opt-in `--trace-ops` for test leak tracing (made opt-in because of a performance regression), `AbortSignal.timeout()`, and stricter default permissions for tests and workers, plus TypeScript 4.6 and V8 10.0.

The quest for software engineering knowledge.

Look:
Layout: