We have VMs, Containers and now I discovered Isolates

Cloudflare as workers to run serverless code without using containers:

So it seems that Isolates is based on:

What we ended up settling on was a technology built by the Google Chrome team to power the Javascript engine in that browser, V8: Isolates.

And they define Isolates as:

Isolates are lightweight contexts that group variables with the code allowed to mutate them. Most importantly, a single process can run hundreds or thousands of Isolates, seamlessly switching between them. They make it possible to run untrusted code from many different customers within a single operating system process. They’re designed to start very quickly (several had to start in your web browser just for you to load this web page), and to not allow one Isolate to access the memory of another.

We pay the overhead of a Javascript runtime once, and then are able to run essentially limitless scripts with almost no individual overhead. Any given Isolate can start around a hundred times faster than I can get a Node process to start on my machine. Even more importantly, they consume an order of magnitude less memory than that process.

Anyone knows more about the use of Isolates outside the use in the Browser and Cloudflare workers?

Am I missing any other technology as an alternative to VMs or containers? (other then the BEAM :wink: )

6 Likes