The Rust-native distributed runtime for Kubernetes.
Flockscale builds Swath, a TLA+-verified distributed compute engine for Python, AI evaluation rollouts, and data pipelines. Run in your own Amazon EKS or Google GKE VPC with sub-millisecond warm task latency, zero-copy shared memory, and automatic OOM recovery.
Familiar Python decorators. Zero cluster babysitting.
Write normal Python tasks and stateful actors. Deploy on your existing Amazon EKS (Karpenter) or Google GKE cluster with a single Helm release.
import grue # Swath OSS Python SDK
grue.init("swath-gateway.swath.svc:50061")
@grue.remote(
cpus=1,
memory_mb=256,
auto_resize_on_oom=True,
max_memory_mb=4096,
)
def run_eval_rollout(prompt_batch):
# If this batch OOMs, Swath doubles memory_mb,
# provisions a high-mem Pod, and retries cleanly.
return score_batch(prompt_batch)
refs = [run_eval_rollout.remote(b) for b in batches]
results = grue.get(refs)
# Install Swath Control Plane + Demand-Driven Autoscaler
helm upgrade --install swath ./deploy/k8s/helm/swath \
--namespace swath --create-namespace \
-f values-eks-karpenter.yaml
# Scale-from-zero: 0 worker Pods at idle.
# Unschedulable CPU / GPU / high-mem demand triggers
# tightest-fit NodePool Pods within 300ms.
# Idle Pods drain gracefully (object-aware) back to 0.
Engineered from first principles in Rust.
No distributed lock storms, no HTTP/2 gRPC bottlenecks in the scheduler, and no Docker-in-Docker inside Kubernetes Pods.
Single-Writer Event Loops (Zero Mutex)
Core control-plane state (ControlState) and node state (NodeInner) run lock-free single-writer event loops over bounded mpsc channels and raw length-prefixed TCP prost frames.
TLA+-Verified Refcounting & Lineage
Split data vs. lineage reference counts, nested ObjectRef capture, epoch fencing, and orphan scoping are formally verified in TLA+ and mirrored 1:1 by deterministic Rust crash simulation tests.
Zero-Copy /dev/shm Data Plane
Payloads above 64 KiB bypass the control plane and Unix socket entirely, staging directly in Linux /dev/shm (emptyDir: Memory on K8s) with single-flight peer fetch coalescing and automatic disk spill.
Automatic OOM Auto-Bump & Object-Aware Drain
Proactive per-worker RSS guarding catches runaway memory before Kubernetes memory.oom.group=1 kills sibling tasks, doubles memory_mb, and schedules onto a larger pool. Scale-down drains empty nodes first to protect pinned objects.
Two unprivileged Kubernetes modes. Zero Docker-in-Docker.
Never requires privileged: true. Choose Mode 1 for universal cloud compatibility (including GKE Autopilot and AWS Fargate) or Mode 2 for per-task multi-image execution on EKS and GKE Standard.
| Deployment Mode | Container Isolation | Warm Task RTT | Supported Clouds |
|---|---|---|---|
| Mode 1: Pod-per-NodePool One image per pool + demand-driven Pod autoscaler |
Pod-level cgroup v2 + 15 ms per-worker RSS guard | 0.38 ms | EKS, GKE Standard, GKE Autopilot, AWS Fargate, AKS |
| Mode 2: Sibling Worker Pods Per-task arbitrary OCI images via initContainer injection |
Dedicated K8s Pod per worker + optional gVisor / Kata |
1.3 ms | EKS (EC2 / Karpenter), GKE Standard, AKS, bare-metal k3s |
Bare-Metal / VM Docker Mode--runtime=docker without Kubernetes |
Per-worker Docker cgroup v2 (memory.max + nano_cpus) |
1.2 ms | EC2, CoreWeave, Lambda, on-prem Linux servers |
Measured on real hardware, not synthetic mocks.
Every figure below comes from end-to-end benchmarks over real TCP sockets, real Linux /dev/shm, real Docker 29.1 cgroups, and live Kubernetes k3s / kind clusters.
| Workload / Metric | Environment | Measured Result |
|---|---|---|
Warm stateless Python task RTT (zero-gRPC LocalDriver) |
Linux x86_64 (1 node) | 0.38 ms (3.3x faster than Ray 1.24 ms) |
| Pipelined stateful Actor calls | Linux x86_64 | 17,230 calls / sec |
| 1-node 50 MB broadcast object fan-out | Linux x86_64 (/dev/shm) |
7.0 GB / sec |
| Kubernetes Mode 1 scale-from-zero (0 → 1 Pod + result) | k3s v1.37 (Helm chart) | 705 ms – 1,040 ms |
Kubernetes Mode 1 real 260 MiB OOM → auto-bump → high-mem Pod |
k3s v1.37 (cgroup v2) | 960.7 ms (0 small-Pod restarts) |
| Kubernetes Mode 2 cross-Pod 20 MiB → 10 MiB zero-copy SHM pipeline | k3s v1.37 (2 distinct OCI images) | 83.0 ms (1.3 ms warm reuse) |
| Enterprise HA single Regional Cell control plane | Real TCP prost (2,000 nodes) |
3.63M tasks / sec (25 ms failover) |
Open-source core. Commercial Enterprise HA in your VPC.
Deploy in your own AWS or GCP account. Your code, models, and data never leave your VPC.
Free forever. Full single-control-plane engine for teams up to hundreds of nodes.
- Single-writer Rust control plane (550k+ tasks/s)
- TLA+-verified refcounting, lineage & actors
- Kubernetes Mode 1 & Mode 2 Helm charts
- Demand-driven, object-aware autoscaler + OOM auto-bump
- Zero-copy
/dev/shm+ C ABI worker runtime
High-availability control plane, multi-thousand-node scale, and enterprise SLA. Available via direct contract or AWS / GCP Marketplace commit drawdown.
- 3-tier Hierarchical HA Cells (3.63M/s per Cell, 25 ms failover)
- 42 ns optimistic node-local scheduler (45.9M/s effective)
- Multi-tenant RBAC, SSO, audit logging & gVisor sandbox profiles
- Direct engineering Slack channel & Ray/KubeRay migration support
- AWS EDP & Google Cloud Marketplace billing support