AI news ·
SGLang becomes a first-class inference engine in LLM-d with Kubernetes-native wide expert parallelism and tiered KV caching
SGLang joins vLLM as a Kubernetes-native inference engine for GLM-5.2, letting operators choose either backend. Tiered KV-cache offloading raised output 3.94x at concurrency 128 and cut median time-to-first-token from 174.2 seconds to 20.1 seconds.

A joint engineering effort between the llm-d and SGLang communities has made SGLang a first-class, Kubernetes-native inference engine for serving GLM-5.2, adding it alongside vLLM in the project's tested reference deployment. The integration lets platform teams run SGLang's Wide-Expert Parallelism (Wide-EP) runtime with the same disaggregated orchestration and prefix-cache-aware routing previously available only for vLLM, while new tiered KV-cache offloading keeps long-context agent sessions alive through high concurrency and pod failures.
Operators can now choose SGLang as a serving backend by swapping the engine-specific deployment overlay and router configuration. On a 16-GPU single-replica deployment, adding host RAM as a second-level cache raised output 3.94x at concurrency 128 and cut median time-to-first-token (TTFT) from 174.2 seconds to 20.1 seconds. Scaling to 32 GPUs across two prefill replicas and a two-node decode pool cut median TTFT another 5.9x to 3.43 seconds, while a shared storage tier restored 99.94% of cached tokens during live pod failover.
Engine-agnostic architecture
llm-d separates cluster-level serving primitives from engine-specific execution. Multi-node prefill and decode pools run as native Kubernetes workloads through a DisaggregatedSet, with coordinated gang scheduling, rolling updates, and Dynamic Resource Allocation for GPUs and RDMA NICs. Instead of exposing a multi-GPU pod as one aggregated endpoint, llm-d registers each attention data-parallel (DP) rank as its own InferencePool endpoint so the router can target each GPU's separate KV cache directly.
The Endpoint Picker (EPP) inference router parses each request and tracks which prefixes are cached per rank and how many tokens are in flight. It selects the prefill rank holding the warm prefix and the least-loaded decode rank, while a routing-proxy sidecar on the decode pod handles the prefill-to-decode handshake. Because these primitives live at the platform layer, adding SGLang did not require a parallel routing stack or custom operator workflow.
Making SGLang Kubernetes-native
Integrating SGLang's Wide-EP runtime into llm-d exposed a boundary mismatch. In Wide-EP deployments, MoE experts are shared across GPUs while each attention-DP rank owns a separate KV cache. A single node-level endpoint could not satisfy llm-d's requirement that every DP rank act as an independent server with its own port, P/D pairing handshake, and health signals.
Contributors added an embedded Rust HTTP server for each DP rank with per-rank warmup readiness, making every rank a routable InferencePool endpoint across single- and multi-node pools. They replicated P/D pairing state across all rank listeners, carried routing metadata across OpenAI and native APIs, and used standard Linux DMA-BUF RDMA for KV transfers. Per-rank model and launch metadata, correlated P/D traces, and SGLang KV-event decoding now give operators per-endpoint visibility in logs and traces.
Tiered KV-cache offloading in production
Using SGLang's HiCache on the prefill pool, the team evaluated a three-tier memory hierarchy on 8-GPU NVIDIA H200 nodes with ConnectX-7 RoCE and a 9,000 GiB Managed Lustre volume. The GPU HBM layer holds roughly 2.09 million tokens per 8-GPU pod. Host RAM, transferred over direct PCIe Gen5 DMA when pages evict from HBM, expands a single pod to 17.5 million tokens. Shared storage on a ReadWriteMany PersistentVolumeClaim holds approximately 163 million tokens, with a client-side metadata cache so each rank remembers pages it has already seen.
Past concurrency 32 on a single 16-GPU replica, active sessions exceeded the HBM budget and dropped the cache hit rate to 6.0%. Offloading to host RAM preserved 85% to 95% cache reuse across the full sweep. During a live failover test where one prefill pod was deleted mid-workload, the shared storage tier restored 99.94% of failed-over prefix tokens instead of recomputing them, cutting cold-replica recovery TTFT by 57% from 38.8 seconds to 16.8 seconds.
Deploying the stack
Deploying the SGLang GLM-5.2 stack on llm-d takes two steps: installing the standalone inference router with sglang.values.yaml, and applying one of the deployment overlays from the project's guides. Single-replica 16-GPU and multi-replica 32-GPU configurations are available, with an optional Shared L3 component for deployments that need resilience to Spot preemptions, upgrades, or multi-replica failover.
Why this matters for IT operations and development teams
For teams running inference at scale, the integration means one Kubernetes control plane can manage two serving engines without duplicating routing, autoscaling, or cache-management infrastructure. The tiered caching results provide a concrete playbook: run L1 plus host RAM on steady single-pod deployments for throughput, and add shared storage when pod evictions or cold starts become a reliability concern. The configurations are available as ready-to-apply Kustomize overlays, reducing the operational burden of tuning KV-cache hierarchies by hand. Professionals building or maintaining inference platforms can explore related patterns in AI Systems Admin Courses.