flâneur — a map of the web's best reading

Lambda on hard mode: Inside Modal's web infrastructure | Modal Blog

modal.com · 3,906 words · saved by 1 readers

At Modal, we built an HTTP and WebSocket stack on our platform. In other words, your serverless functions can take web requests. This was tricky! HTTP has quite a few edge cases, so we used Rust for its speed and to help manage the complexity. But even so, it took a while to get right. We recently wrapped up this feature by introducing full WebSocket support (real-time bidirectional messaging). We call this service modal-http, and it sits between the Web and our core runtime. You can deploy a simple web endpoint to a *.modal.run URL by running some Python code: (This takes 0.747 seconds to deploy today.) But you can also run a much larger compute workload. For example, to set up a data-intensive video processing endpoint: This post is about the behind-the-scenes of serving a web endpoint on Modal. How does your web request get translated into an autoscaling serverless invocation? What makes our HTTP/WebSocket implementation particularly interesting is its lack of limits. Serverless com

All posts Back Engineering March 14, 2024 • 20 minute read Lambda on hard mode: Inside Modal's web infrastructure Eric Zhang Founding Engineer At Modal, we built an HTTP and WebSocket stack on our platform. In other words, your serverless functions can take web requests. This was tricky! HTTP has quite a few edge cases, so we used Rust for its speed and to help manage the complexity. But even so, it took a while to get right. We recently wrapped up this feature by introducing full WebSocket support (real-time bidirectional messaging). We call this service modal-http , and it sits between the W

Explore this link on the map →

related reading