Skip to content

Commit cbfc22d

Browse files
clauded-gubert
authored andcommitted
feat(apps-engine): default runtime backend to node
Swap the default apps-engine runtime backend from deno to node so the node runtime is exercised by the standard API test suite. The deno runtime can still be selected via APPS_ENGINE_RUNTIME_BACKEND='deno'. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01QzzSPVtd9ZcpaezJQtw6mm
1 parent 5ba7bd5 commit cbfc22d

2 files changed

Lines changed: 8 additions & 2 deletions

File tree

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
---
2+
'@rocket.chat/apps': minor
3+
'@rocket.chat/meteor': minor
4+
---
5+
6+
Changes the default apps-engine runtime backend from `deno` to `node`. The previous behavior can be restored by setting the environment variable `APPS_ENGINE_RUNTIME_BACKEND='deno'`

packages/apps/src/server/managers/AppRuntimeManager.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,15 +19,15 @@ export type ExecRequestOptions = {
1919
timeout?: number;
2020
};
2121

22-
const { APPS_ENGINE_RUNTIME_BACKEND = 'deno' } = process.env;
22+
const { APPS_ENGINE_RUNTIME_BACKEND = 'node' } = process.env;
2323

2424
export const nodeRuntimeFactory = (manager: AppManager, appPackage: IParseAppPackageResult, storageItem: IAppStorageItem) =>
2525
new NodeRuntimeSubprocessController(manager, appPackage, storageItem);
2626

2727
export const denoRuntimeFactory = (manager: AppManager, appPackage: IParseAppPackageResult, storageItem: IAppStorageItem) =>
2828
new DenoRuntimeSubprocessController(manager, appPackage, storageItem);
2929

30-
const defaultRuntimeFactory = APPS_ENGINE_RUNTIME_BACKEND === 'node' ? nodeRuntimeFactory : denoRuntimeFactory;
30+
const defaultRuntimeFactory = APPS_ENGINE_RUNTIME_BACKEND === 'deno' ? denoRuntimeFactory : nodeRuntimeFactory;
3131

3232
export class AppRuntimeManager {
3333
private readonly subprocesses: Record<string, IRuntimeController> = {};

0 commit comments

Comments
 (0)