Skip to content

Endojs and memory / cpu management for untrusted code #1634

Answered by kriskowal
dodtsair asked this question in Q&A
Discussion options

You must be logged in to vote

For the moment, the idea is that each guest will by default get its own worker and must ask the user for more workers. So the guest can use for (;;); to foul its own environment. The user can also choose to place multiple tenants in a single worker, allowing them to interfere with each other’s availability. The daemon monitors event loop health. The user can terminate unhealthy workers.

In this early incarnation of the Pet Daemon, workers are Node.js processes and we do not impose heap constraints. We could conceivably recruit the OS to cap this, and of course in the worst case, the OOM killer comes for us all.

In a later incarnation, we may put workers in XS xsnap child processes the way…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by dckc
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants