-
Notifications
You must be signed in to change notification settings - Fork 33
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
use experimental worker_threads to run tasks #29
Conversation
workerStartTime.should.be.at.least(callTime); | ||
workerNodes.workersQueue.forEach(worker => { | ||
const startDate = worker.process.startDate; | ||
if (startDate) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't like this - suggestions welcomed
lib/worker/process.js
Outdated
// report readiness on a first message received from the child | ||
// process (as it means that the child has loaded all the stuff | ||
// into a memory and is ready to handle the calls) | ||
if (message === 'ready') { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't like this - suggestions welcomed
dda8c0a
to
40d674a
Compare
lib/worker/process.js
Outdated
stdio: [0, 1, 2, 'pipe', 'ipc'] | ||
this.startDate = null; | ||
|
||
const child = new worker.Worker(require.resolve('./child-loader')); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
rename child
to thread
?
5b55aa7
to
df9546f
Compare
Travis is now configured to use yarn, so we should update |
}, | ||
"scripts": { | ||
"docs": "jsdoc2md -l off -t docs-src/Readme.hbs lib/*.js > Readme.md; echo", | ||
"test": "mocha --trace-warnings -r tests/utils/setup.js {lib,tests}/**/*.spec.js", | ||
"test": "node --experimental-worker node_modules/.bin/_mocha --trace-warnings -r tests/utils/setup.js {lib,tests}/**/*.spec.js", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can get rid of msgpack-lite
dependency, as it's not needed anymore.
next
)