BT

Facilitating the Spread of Knowledge and Innovation in Professional Software Development

Write for InfoQ

Topics

Choose your language

InfoQ Homepage News AWS Introduces an Experimental Low Latency Runtime for Faster, More Efficient Serverless Apps

AWS Introduces an Experimental Low Latency Runtime for Faster, More Efficient Serverless Apps

This item in japanese

AWS recently open-sourced its JavaScript runtime, called LLRT (Low Latency Runtime), an experimental, lightweight JavaScript runtime designed to address the growing demand for fast and efficient Serverless applications.

On GitHub, the company claims LLRT offers up to over ten times faster startup and up to two times lower cost than other JavaScript runtimes running on AWS Lambda. It's built in Rust, utilizing QuickJS as a JavaScript engine, ensuring efficient memory usage and quick startup. In addition, the runtime integrates with Lambda and AWS SDK (v3).

LLRT is another JavaScript runtime that focuses on the specific demands of a serverless environment, which are not fully met by existing options like Node.jsBun, and Deno, designed for general-purpose applications. Unlike these runtimes, LLRT does not include a Just-In-Time (JIT) compiler, which reduces system complexity and runtime size while conserving CPU and memory resources, leading to faster application startup times.

On a Reddit thread, a respondent explains:

The speedup mostly comes from a limitation: LLRT requires one to bundle their code and dependencies into a single .js file and thus eliminates all the file system lookups that happen during the module resolution phase in Node.

Also, they pre-package, precompile (into bytecode), and preload bits of AWS SDK and then compare that to a general-purpose runtime like Node or Bun that has to load the AWS SDK libraries as JS files and interpret them on application start. I bet this is where the 99% of performance benefits come from.

LLRT is most efficient when utilized in smaller Serverless functions, focusing on data transformation, real-time processing, AWS service integrations, and authorization and validation tasks.

A respondent on a Hacker News thread commented:

This seems ideal for places where you use Lambda as glue, like for routing requests or authorization policy decisions. But for an application that's doing a lot of thinking, keep in mind v8 jitless is about 3x faster than QuickJS, and with JIT it’s about 30x faster than quickjs. I’m curious to see where the break-even point is for various workloads comparing the two, and also numbers versus Bun, which starts quicker than Node but has comparable top-end JIT performance.

However, Zemnytskyi Dmytro, a programmer and software architect, tweeted:

This will complicate lambda development even further. Uncompatible dependencies and tools. Even more vendor lock-in. I'm skeptical about it. I'd better write entire lambda in rust then.

And lastly, the conclusion of an AWS Bites episode on LLRT:

Overall, LLRT shows promise but needs more stability, support, and real-world testing before it can be recommended for production use.

About the Author

Rate this Article

Adoption
Style

BT