Baike.dev
All toolsOnline toolsAI codingTrendingOpen sourceNewsSubmit
Log in
< Back to tools
L

llrt

> 编程语言
Open source

LLRT (Low Latency Runtime) is an experimental, lightweight JavaScript runtime designed to address the growing demand for fast and efficient Serverless applicati

8.8K stars0 likes2 views
WebsiteGitHub

About

LLRT (Low Latency Runtime) is an experimental, lightweight JavaScript runtime designed to address the growing demand for fast and efficient Serverless applicati

LLRT (Low Latency Runtime) is a lightweight JavaScript runtime designed to address the growing demand for fast and efficient Serverless applications. LLRT offers up to over 10x faster startup and up to 2x overall lower cost compared to other JavaScript runtimes running on AWS Lambda

It's built in Rust, utilizing QuickJS as JavaScript engine, ensuring efficient memory usage and swift startup.

[!WARNING] LLRT is an experimental package. It is subject to change and intended only for evaluation purposes.

LLRT - DynamoDB Put, ARM, 128MB:

Node.js 20 - DynamoDB Put, ARM, 128MB:

HTTP benchmarks measured in round trip time for a cold start (why?)

Configure Lambda functions to use LLRT

Download the last LLRT release from https://github.com/awslabs/llrt/releases

Option 1: Custom runtime (recommended)

Choose Custom Runtime on Amazon Linux 2023 and package the LLRT bootstrap binary together with your JS code.

Option 2: Use a layer

Choose Custom Runtime on Amazon Linux 2023, upload llrt-lambda-arm64.zip or llrt-lambda-x64.zip as a layer and add to your function

Option 3: Package LLRT in a container image

See our AWS SAM example or:

dockerfile
FROM --platform=arm64 busybox
WORKDIR /var/task/
COPY app.mjs ./
ADD https://github.com/awslabs/llrt/releases/latest/download/llrt-container-arm64 /usr/bin/llrt
RUN chmod +x /usr/bin/llrt

ENV LAMBDA_HANDLER "app.handler"

CMD [ "llrt" ]

Option 4: AWS SAM

The following example project sets up a lambda instrumented with a layer containing the llrt runtime.

Option 5: AWS CDK

You can use cdk-lambda-llrt construct library to deploy LLRT Lambda functions with AWS CDK.

typescript
import { LlrtFunction } from "cdk-lambda-llrt";

const handler = new LlrtFunction(this, "Handler", {
  entry: "lambda/index.ts",
});

See Construct Hub and its examples for more details.

That's it

[!IMPORTANT] Even though LLRT supports ES2023 it's NOT a drop in replacement for Node.js. Consult Compatibility matrix and API for more details. All dependencies should be bundled for a browser platform and mark included @aws-sdk packages as external.

Testing & ensuring compatibility

The best way to ensure your code is compatible with LLRT is to write tests and execute them using the built-in test runner. The test runner currently supports Jest/Chai assertions. There are three main types of tests you can create:

Unit Tests

  • Useful for validating specific modules and functions in isolation
  • Allow focused testing of individual components

End-to-End (E2E) Tests

  • Validate overall compatibility with AWS SDK and WinterTC compliance
  • Test the integration between all components
  • Confirm expected behavior from end-user perspective
  • For more information about the E2E Tests and how to run them, see here.

Web Platform Tests (WPT)

  • Useful for validating LLRT’s behavior against standardized browser APIs and runtime expectations
  • Ensure compatibility with web standards and cross-runtime environments
  • Help verify alignment with WinterTC and broader JavaScript ecosystem
  • For setup instructions and how to run WPT in LLRT, see here.

Test runner

Test runner uses a lightweight Jest-like API and supports Jest/Chai assertions. For examples on how to implement tests for LLRT see the /tests folder of this repository.

To run tests, execute the llrt test command. LLRT scans the current directory and sub-directories for files that ends with *.test.js or *.test.mjs. You can also provide a specific test directory to scan by using the llrt test -d <directory> option.

The test runner also has support for filters. Using filters is as simple as adding additional command line arguments, i.e: llrt test crypto will only run tests that match the filename containing crypto.

Compatibility matrix

[!NOTE] LLRT only support a fraction of the Node.js APIs. It is NOT a drop in replacement for Node.js, nor will it ever be. Below is a high level overview of partially supported APIs and modules. For more details consult the API documentation

Node.js API Node.js LLRT
node:assert ✔︎ ✔︎️⚠️
node:async_hooks ✔︎ ✔︎️⚠️
node:buffer ✔︎ ✔︎️⚠️
node:child_process ✔︎ ✔︎⚠️
node:cluster ✔︎ ✘
node:console ✔︎ ✔︎⚠️
node:crypto ✔︎ ✔︎⚠️
node:dgram ✔︎ ✘
node:diagnostics_channel ✔︎ ✘
node:dns ✔︎ ✔︎⚠️
node:events ✔︎ ✔︎⚠️
node:fs ✔︎ ✔︎⚠️
node:fs/promises ✔︎ ✔︎⚠️
node:http ✔︎ ✘⏱
node:http2 ✔︎ ✘
node:https ✔︎ ✘⏱
node:inspector ✔︎ ✘
node:inspector/promises ✔︎ ✘
node:module ✔︎ ✔︎⚠️
node:net ✔︎ ✔︎⚠️
node:os ✔︎ ✔︎⚠️
node:path ✔︎ ✔︎⚠️
node:perf_hooks ✔︎ ✔︎⚠️
node:process ✔︎ ✔︎⚠️
node:querystring ✔︎ ✘
node:readline ✔︎ ✘
node:readline/promises ✔︎ ✘
node:repl ✔︎ ✘
node:sqlite ✔︎ ✘
node:stream ✔︎ ✔︎*
node:stream/promises ✔︎ ✔︎*
node:stream/web ✔︎ ✔︎⚠️
node:string_decoder ✔︎ ✔︎
node:test ✔︎ ✘
node:timers ✔︎ ✔︎⚠️
node:tls ✔︎ ✘⏱
node:tty ✔︎ ✔︎⚠️
node:url ✔︎ ✔︎⚠️
node:util ✔︎ ✔︎⚠️
node:v8 ✔︎ ✘**
node:vm ✔︎ ✘
node:wasi ✔︎ ✘
node:worker_threads ✔︎ ✘
node:zlib ✔︎ ✔︎⚠️
LLRT API Node.js LLRT
llrt:codec ✘ ✔︎
llrt:qjs ✘ ✔︎
llrt:util ✘ ✔︎
llrt:xml ✘ ✔︎
Web Platform API LLRT
COMPRESSION ✘⏱
CONSOLE ✔︎⚠️
DOM ✔︎⚠️
ECMASCRIPT ✔︎⚠️
ENCODING ✔︎⚠️
FETCH ✔︎⚠️
FILEAPI ✔︎⚠️
HR-TIME ✔︎
HTML ✔︎⚠️
STREAMS ✔︎⚠️
URL ✔︎
URLPATTERN ✘⏱
WASM-JS-API-2 ✘
WASM-WEB-API-2 ✘
WEBCRYPTO ✔︎⚠️
WEBIDL ✔︎⚠️
XHR ✔︎⚠️
Other features LLRT
async/await ✔︎
esm ✔︎
cjs ✔︎
Intl ✔︎⚠️
Temporal ✔︎⚠️

⚠️ = partially supported in LLRT
⏱ = planned partial support
* = Not native
** = The module.registerHooks() API allows you to emulate some functionality. See also example/register-hooks.

Using node_modules (dependencies) with LLRT

Since LLRT is meant for performance critical application it's not recommended to deploy node_modules without bundling, minification and tree-shaking.

LLRT can work with any bundler of your choice. Below are some configurations for popular bundlers:

[!WARNING] LLRT implements native modules that are largely compatible with the following external packages. By implementing the following conversions in the bundler's alias function, your application may be faster, but we recommend that you test thoroughly as they are not fully compatible.

Node.js LLRT
fast-xml-parser llrt:xml

ESBuild

bash
esbuild index.js --platform=browser --target=es2023 --format=esm --bundle --minify --external:@aws-sdk --external:@smithy

Rollup

javascript
import resolve from "@rollup/plugin-node-resolve";
import commonjs from "@rollup/plugin-commonjs";
import terser from "@rollup/plugin-terser";

export default {
  input: "index.js",
  output: {
    file: "dist/bundle.js",
    format: "esm",
    sourcemap: true,
    target: "es2023",
  },
  plugins: [resolve(), commonjs(), terser()],
  external: ["@aws-sdk", "@smithy"],
};

Webpack

javascript
import TerserPlugin from "terser-webpack-plugin";
import nodeExternals from "webpack-node-externals";

export default {
  entry: "./index.js",
  output: {
    path: "dist",
    filename: "bundle.js",
    libraryTarget: "module",
  },
  target: "web",
  mode: "production",
  resolve: {
    extensions: [".js"],
  },
  exter

Issues· 44 open

View all issuesOpen on GitHub
  • #1792

    fetch: Origin header added to non-GET/HEAD requests breaks OAuth2 client_credentials against Microsoft Entra ID (AADSTS9002326)

    Updated Sep 24, 2026
  • #1769

    Error calling CognitoIdentityProviderClient methods: "Failed to fetch"

    Updated Sep 16, 2026
  • #1738

    Proposal: Implement "Modern Algorithms in the Web Cryptography API" (WICG specification)

    Updated Aug 25, 2026
  • #635

    LLRT Roadmap & Priorities

    Updated Aug 19, 2026
  • #1170

    Support for `AsyncLocalStorage` from `async_hooks`

    enhancementUpdated Apr 3, 2026
  • #518

    SyntaxError: Could not find export 'fromNodeProviderChain' in module '@aws-sdk/credential-providers'

    Updated Mar 5, 2026
  • #493

    Will llrt have plans to support WebAssembly ?

    Updated Feb 27, 2026
  • #808

    React renderToReadableStream

    Updated Feb 9, 2026
  • #40

    HTTP & HTTPS Modules

    enhancementUpdated Dec 7, 2025
  • #970

    globals are missing WebCryptoAPI's interfaces/classes

    enhancementUpdated Dec 3, 2025

> Tags

Rust

No comments yet. Be the first to share.

> Details

PublishedAug 1, 2026
UpdatedSep 29, 2026
Category编程语言
PricingOpen source

> Related tools

T
TypeScript
JavaScript 的超集,为前端与全栈提供静态类型
P
Python
通用编程语言,广泛用于 Web、数据与 AI
G
Go
Google 推出的简洁高效系统语言