Re:How Shopify Uses WebAssembly Outside of the Browser
by sradman on Saturday December 19, 2020 @08:48AM
(#25477370)
We are talking about two alternative architectures, Cloudflare Workers and Fastly Compute@Edge, solving the same problem: how to run server-side untrusted code. Cloudflare runs a sandboxed V8 runtime in-process with its Nginx servers while Fastly chose a Function-as-Service platform using Lucet compiled WebAssembly modules with minimal runtime and fast startup. Fastly’s Varnish servers invoke FaaS modules and it sounds like Shopify's Ruby centric platform is better suited to this architecture.
[ Parent
| on HN ]
Re:How Shopify Uses WebAssembly Outside of the Browser
by kentonv on Saturday December 19, 2020 @02:40PM
(#25480461)
> Cloudflare runs a sandboxed V8 runtime in-process with its Nginx servers
Maybe nitpicking, but that's not quite right. The Workers Runtime is a separate process from nginx and is inside a heavy second-layer sandbox separating it from the rest of the system. Multiple Workers Runtime instances exist on each machine to serve different tiers of customers, and each instance may additionally create further subprocesses to provide extra sandboxing adaptively.
Here's a diagram: https://blog.cloudflare.com/mitigating-spectre-and-other-sec...
(In that diagram, the "Inbound/Outbound HTTP Proxy" boxes are, at least at present, nginx, but the big middle box is a new server architecture written from scratch.)
Re:How Shopify Uses WebAssembly Outside of the Browser
by sradman on Saturday December 19, 2020 @04:08PM
(#25481219)
That is not nitpicking at all. Definitely not in-process. Thanks for pointing that out.
Re:How Shopify Uses WebAssembly Outside of the Browser
by robertlagrant on Saturday December 19, 2020 @05:07PM
(#25481705)
Aah, that's why Fastly's involved. Thanks!