Nitro v3 Beta Update: Built-in Tracing, Smarter Dep Tracing, and Vercel Queues

Nitro v3 Beta Update: Built-in Tracing, Smarter Dep Tracing, and Vercel Queues

lschvn

Nitro v3's public beta continues to evolve rapidly. The April 15 update (v3.0.260415-beta) ships a set of developer-experience and production-readiness features that bring the v3 release closer to general availability.

Built-in Tracing Channels

The headline addition is experimental tracing channel support (PR #4001). Nitro now emits structured trace spans for request lifecycle events — covering route matching, handler execution, cache hits and misses, and database query timing — directly from the framework's core. No OpenTelemetry SDK wiring required; tracing is a first-class Nitro feature.

This matters for teams running Nitro in production who want lightweight observability without instrumenting every route by hand. The trace output plugs into any OpenTelemetry-compatible collector.

Smarter Dependency Tracing with Full-trace Mode

Nitro's traceDeps tool gets a meaningful upgrade (PR #4175). The new full-trace mode and custom trace options give developers control over how Nitro analyzes your dependency graph during the build.

The key practical improvement: the upstream nf3 tracer now includes a growing native-packages database and automatic detection of optional dependencies. If your project uses packages with native binaries — sharp for image processing, canvas, better-sqlite3, or similar — Nitro can now detect these automatically and avoid incorrect bundling, which has been a common source of "works locally, breaks in production" errors.

This is particularly relevant for serverless deployments where the runtime environment differs from your local machine. Nitro can now reason about which dependencies need to stay out of the bundle and rely on the platform's installed packages instead.

Vercel Queues and Per-route Function Config

The Vercel deployment preset gains two production features.

Vercel Queues: Nitro route handlers can now enqueue async work using Vercel's queue infrastructure. You define background task handlers with nitro.tasks, deploy to Vercel, and use the Vercel SDK from your route handlers. The preset handles configuration automatically. This brings durable async execution to Nitro without needing a separate queue infrastructure like BullMQ or SQS.

Per-route function config override: Individual routes can now override the default Vercel function configuration — memory limit, timeout, and maxDuration. This is useful when one specific route needs more resources than the rest of your application. Previously, you had to set function config globally or use workarounds.

Tencent EdgeOne Pages Deployment

Nitro's deploy-anywhere promise adds another target: Tencent EdgeOne Pages. The new edgeone-pages preset uses the EdgeOne Pages Build Output API v3 and is documented at nitro.build/deploy/providers/edgeone. For teams targeting Chinese edge infrastructure, this is a direct deployment path without wrapping Nitro output manually.

H3 v2 Security and Compatibility Fixes

The underlying H3 HTTP framework updates from rc.16 to rc.20 in this release, bringing several important fixes:

  • Path traversal protection: Double-encoded dot segments in URLs are now rejected before they reach your route handlers, closing a potential traversal vector in static file serving
  • Open redirect protection: redirectBack() now validates that the redirect target doesn't use a protocol-relative path, preventing //attacker.com redirects
  • Stricter streaming body size checks: Enforces stream-based content-length limits regardless of the Content-Length header, making streaming responses more predictable
  • Cookie RFC 6265bis compliance: Cookie parsing and serialization now conform to the updated RFC, fixing edge cases with cookie limits and parsing behavior that differed across browsers
  • Unbounded chunked cookie count fix: Prevents a DoS vector where an attacker could set an arbitrary number of cookies to overflow server-side storage

ocache and unstorage Improvements

On the caching side, ocache gains cache invalidation via handler.invalidate() and multi-tier cache support — useful for implementing cache-aside patterns where you want to explicitly evict entries on demand. unstorage now proactively flushes expired memory entries rather than waiting for the next access, which reduces memory pressure for long-running Nitro processes.

Documentation Additions

Nitro.build gains new guides for OpenAPI and WebSocket — both areas where Nitro has had support but lacked formal documentation. The OpenAPI guide covers automatic route documentation generation from Nitro's route metadata; the WebSocket guide shows how to set up WebSocket endpoints using Nitro's built-in support.

The Bottom Line

The April beta update shows Nitro v3 maturing toward GA with production infrastructure features rather than just developer-facing ergonomics. The tracing channels, native dependency detection, and Vercel queue support are all targeted at teams running Nitro at scale. If you're deploying Nitro to Vercel, the queue support alone is worth evaluating.

Frequently Asked Questions

Related articles

More coverage with overlapping topics and tags.

Astro 6.1.8 Patches Critical Netlify Deploy Bug and Image Endpoint Security Flaw
TypeScript

Astro 6.1.8 Patches Critical Netlify Deploy Bug and Image Endpoint Security Flaw

Astro 6.1.8 fixes a regression where build output filenames containing special characters caused deploy failures on Netlify and Vercel, and patches a content-type confusion vulnerability in the built-in image endpoint that could serve non-SVG content as SVG.
Inertia.js 3.0 Bridges the Gap Between SPAs and Server-Side Frameworks
Vue

Inertia.js 3.0 Bridges the Gap Between SPAs and Server-Side Frameworks

Inertia.js 3.0 ships with support for React, Vue, and Svelte SPAs backed by Laravel, Rails, or Django — no API layer required. Here's what's new in the 'Modern Monolith' approach to building web applications.
Bun Joins Anthropic: What the Acquisition Means for the JavaScript Ecosystem
TypeScript

Bun Joins Anthropic: What the Acquisition Means for the JavaScript Ecosystem

The JavaScript runtime, bundler, and toolkit built by a 14-person team and relied on by millions of developers has been acquired by Anthropic. Bun will remain open source and MIT-licensed, but the roadmap now bends toward AI coding infrastructure.

Comments

Log in Log in to join the conversation.

No comments yet. Be the first to share your thoughts.