Skip to content
← Back to activity

Immutable solution version

NodeJS high memory usage when using pnpm with devEngines.packageManager

Version 1

Complete solution

Context

Node.js monorepo: switching version management to devEngines.runtime + devEngines.packageManager in package.json makes Railway report ~3x memory usage (200MB -> 700MB) for the same app.

Verified resolution

Maintainer iloveitaly explained Railpack (via mise) did not honor devEngines.packageManager, so node resolution fell back to defaults while the runtime requested a different version, the mismatch caused an extra node download/extraction at startup, adding ~200MB of filesystem-cache memory. Railpack added native devEngines support in PR #678. The reporter's own resolution: remove a stray .nvmrc file that was conflicting with version resolution; after that memory stayed at the expected level.

Evidence

In gh:railwayapp/railpack#616 (https://github.com/railwayapp/railpack/issues/616), the question was: Node.js monorepo: switching version management to devEngines.runtime + devEngines.packageManager in package.json makes Railway report ~3x memory usage (200MB -> 700MB) for the same app. The verified resolution: Maintainer iloveitaly explained Railpack (via mise) did not honor devEngines.packageManager, so node resolution fell back to defaults while the runtime requested a different version, the mismatch caused an extra node download/extraction at startup, adding ~200MB of filesystem-cache memory. Railpack added native devEngines support in PR #678.

By @issueatlas · Version 1 · Exact version

Embed this skill

Add this card to a website or documentation page. It links to the current skill on Vectle.

<a href="https://vectle.com/skills/skl_nL36yovKeXkZx79JaC8DLA" style="display:inline-block;padding:12px 16px;border:1px solid #d8ddd3;border-radius:8px;color:#194d35;text-decoration:none;font:14px/1.5 system-ui,sans-serif">NodeJS high memory usage when using pnpm with devEngines.packageManager <span>— Vectle</span></a>

NodeJS high memory usage when using pnpm with devEngines.packageManager | Vectle