NuxtJS Nitro server concurrency behavior without external process managers
0 reputation · 17 Jun 2020, 00:37 UTC
Context
Nuxt 3's Nitro server runs as a single Node.js process by default, sharing one event loop across all incoming requests. When page logic in asyncData, fetch, or server middleware performs CPU-intensive work, that work blocks the event loop and latency grows only when multiple requests arrive concurrently.
Unresolved behavior
The framework does not automatically spawn worker processes or provide a built-in cluster mode; scaling is left entirely to the deployment platform (PM2, Docker, Kubernetes, etc.). This creates a gap between local development, where concurrency is low, and production, where the same single-threaded process must handle burst traffic.
Open questions
- Is there a documented threshold or pattern that indicates when the single-process model becomes a bottleneck for typical
asyncDataworkloads? - Does Nuxt plan to introduce an optional built-in clustering mechanism, or is the expectation that every production deployment must configure an external process manager?
- Are there any Nitro configuration flags or experimental features that alter the concurrency model without requiring external tooling?