Skip to content

Graphorin API reference v0.1.0


Graphorin API reference / @graphorin/security / / IsolatedVMSandboxOptions

Interface: IsolatedVMSandboxOptions

Defined in: packages/security/src/sandbox/isolated-vm.ts:68

Options for createIsolatedVMSandbox(...).

Stable

Properties

PropertyModifierTypeDescriptionDefined in
defaultTimeoutMs?readonlynumberDefault wall-clock timeout (ms). Defaults to 5000.packages/security/src/sandbox/isolated-vm.ts:72
fallback?readonly"fallback-to-worker-threads" | "throw"Adapter to use if the isolated-vm peer is unavailable. Defaults to 'fallback-to-worker-threads'. Set to 'throw' for production builds that must refuse to start when the peer is missing.packages/security/src/sandbox/isolated-vm.ts:78
fallbackAdapter?readonlySandboxImplWorker-threads adapter to fall back to. Required when fallback === 'fallback-to-worker-threads'.packages/security/src/sandbox/isolated-vm.ts:80
memoryLimitMb?readonlynumberMemory limit forwarded to new Isolate({ memoryLimit }). Defaults to 128 MB per DEC-148.packages/security/src/sandbox/isolated-vm.ts:70
peerLoader?readonly() => Promise<IsolatedVMPeerModule>Override the peer-dep loader. Tests pass a stub here so the adapter can run without the native binary.packages/security/src/sandbox/isolated-vm.ts:87
warn?readonly(message) => voidOptional WARN logger called once per process when the fallback engages.packages/security/src/sandbox/isolated-vm.ts:82