-
Notifications
You must be signed in to change notification settings - Fork 106
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
Add resourceLimits support #21
Conversation
@addaleax ... not entirely sure why but the resource limits are being rather flaky on macos here. Sometimes they run fine, next run they fail inconsistently across versions. https://github.com/jasnell/piscina/pull/21/checks?check_run_id=637470841 |
Hm, odd … I’ll try to take a look at that, thanks for letting me know |
Ok, updated to use the |
On that flaky failure, what it is looking like is that, at least sometimes, the error that's terminating the worker is not getting properly caught and routed to the task Promise. |
I don’t think that’s what’s happening – the Promise is rejected, but because there was an |
hmm.. ok, that's fun lol |
Right. We could probably try to detect this in some way, but given that rejected Promises and an |
and for this particular case, attach an |
@jasnell For the test, I’d just increase the limits. Alternatively, we could also enable forwarding things like |
For now, I'll just add the error event handler rather than trying to hunt for limit values that will work consistently. Having the ability to set |
This is good to go 👍 |
@jasnell There’s #21 (review) but if you want you can merge this and I’ll push those changes separately |
Yeah, I had just spotted those :-) |
Fixes: #20