0
0
mirror of https://github.com/nodejs/node.git synced 2024-11-30 15:30:56 +01:00
nodejs/lib/worker_threads.js
Anna Henningsen d855904ef6
worker: allow specifying resource limits
Allow specifying resource limits for the JS engine instance created
as part of a Worker.

PR-URL: https://github.com/nodejs/node/pull/26628
Reviewed-By: Joyee Cheung <joyeec9h3@gmail.com>
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Franziska Hinkelmann <franziska.hinkelmann@gmail.com>
2019-11-05 19:57:13 +01:00

31 lines
468 B
JavaScript

'use strict';
const {
isMainThread,
SHARE_ENV,
resourceLimits,
threadId,
Worker
} = require('internal/worker');
const {
MessagePort,
MessageChannel,
moveMessagePortToContext,
receiveMessageOnPort
} = require('internal/worker/io');
module.exports = {
isMainThread,
MessagePort,
MessageChannel,
moveMessagePortToContext,
receiveMessageOnPort,
resourceLimits,
threadId,
SHARE_ENV,
Worker,
parentPort: null,
workerData: null,
};