Skip to content

Commit 1688652

Browse files
committed
Merge remote-tracking branch 'upstream/main'
# Conflicts: # cmd/ateapi/internal/actoridentity/actoridentity.go # cmd/ateapi/main.go # manifests/ate-install/ate-api-server.yaml
2 parents dab7773 + 03eb099 commit 1688652

88 files changed

Lines changed: 6083 additions & 1570 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/SECURITY.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ valuable, listed roughly from most to least severe:
6565
- **Snapshot integrity and confidentiality**: reading another actor's
6666
suspend/resume snapshot, or resuming an actor from a tampered snapshot.
6767
- **Routing**: traffic intended for one actor delivered to another.
68-
- **Identity**: forging session identity (for example session JWTs).
68+
- **Identity**: forging actor identity (for example actor JWTs).
6969
- **Control-plane authentication and authorization bypass**: reaching
7070
`ateapi` RPCs without valid credentials (mTLS or JWT auth modes),
7171
misusing workerpool client certificates, or acting beyond what valid

.github/workflows/pr-workflow.yaml

Lines changed: 22 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -22,14 +22,18 @@ on:
2222
# evicts caches idle for 7 days). The push-to-main run populates the cache that
2323
# PRs inherit; this refreshes it so PRs keep hitting it (no asset re-download).
2424
- cron: '37 4 * * 1'
25+
# Nothing here writes to the repository: the jobs check the tree out, build it,
26+
# and run it in a throwaway cluster.
27+
permissions:
28+
contents: read
2529
jobs:
2630
run-tests:
2731
runs-on: ubuntu-latest
2832
steps:
2933
- name: Checkout
30-
uses: actions/checkout@v5
34+
uses: actions/checkout@fbc6f3992d24b796d5a048ff273f7fcc4a7b6c09 # v5.1.0
3135
- name: Setup Go
32-
uses: actions/setup-go@v5
36+
uses: actions/setup-go@40f1582b2485089dde7abd97c1529aa768e1baff # v5.6.0
3337
with:
3438
go-version-file: 'go.mod'
3539
- run: go test -v ./...
@@ -52,9 +56,9 @@ jobs:
5256
name: e2e-test (${{ matrix.ateapi-client-auth }})
5357
steps:
5458
- name: Checkout
55-
uses: actions/checkout@v5
59+
uses: actions/checkout@fbc6f3992d24b796d5a048ff273f7fcc4a7b6c09 # v5.1.0
5660
- name: Setup Go
57-
uses: actions/setup-go@v5
61+
uses: actions/setup-go@40f1582b2485089dde7abd97c1529aa768e1baff # v5.6.0
5862
with:
5963
go-version-file: 'go.mod'
6064
- name: Free disk space
@@ -65,7 +69,7 @@ jobs:
6569
df -h /
6670
- name: Cache micro-VM assets
6771
id: microvm-assets
68-
uses: actions/cache@v4
72+
uses: actions/cache@0057852bfaa89a56745cba8c7296529d2fc39830 # v4.3.0
6973
with:
7074
# Assembling the assets (download kata-static + cloud-hypervisor + the
7175
# prebuilt virtiofsd — all downloads on amd64) is fully pinned by assemble.sh,
@@ -110,12 +114,20 @@ jobs:
110114
if: failure()
111115
run: |
112116
kubectl --context kind-kind get actortemplate,workerpool,pods -A -o wide || true
113-
for ns in ate-demo-counter-microvm ate-demo-counter ate-system; do
114-
for p in $(kubectl --context kind-kind get pods -n "$ns" -o name 2>/dev/null); do
115-
echo "=== logs: $ns/$p ==="
116-
kubectl --context kind-kind logs -n "$ns" "$p" --all-containers --tail=200 2>/dev/null || true
117-
done
117+
dump() {
118+
echo "=== logs: $1/$2 ==="
119+
kubectl --context kind-kind logs -n "$1" "$2" --all-containers --tail=300 2>/dev/null || true
120+
}
121+
for p in $(kubectl --context kind-kind get pods -n ate-system -o name 2>/dev/null); do
122+
dump ate-system "$p"
118123
done
124+
# Every worker pod in any namespace: the demo pools plus the e2e suites'
125+
# randomly-named per-test namespaces, which the suites keep on failure.
126+
# The failing actor runs in one of these, so this is where its ateom logs
127+
# (and, for a micro-VM worker, the guest console tail) live.
128+
kubectl --context kind-kind get pods -A -l ate.dev/worker-pool \
129+
-o 'custom-columns=:.metadata.namespace,:.metadata.name' --no-headers 2>/dev/null \
130+
| while read -r ns name; do dump "$ns" "$name"; done
119131
e2e-test:
120132
runs-on: ubuntu-latest
121133
needs: e2e-test-matrix

README.md

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -34,11 +34,11 @@ agents, but rather a system for running them at scale.
3434

3535
[![Agent Substrate Demo](https://img.youtube.com/vi/ZEzkCFJkzjY/hq1.jpg)](https://www.youtube.com/watch?v=ZEzkCFJkzjY)
3636

37-
*Watch the Agent Substrate cluster multiplex ~250 stateful actor sessions across just 8 physical pods.*
37+
*Watch the Agent Substrate cluster multiplex ~250 stateful actors across just 8 physical pods.*
3838

3939
This demo highlights the core developer experience and "Agentic Infrastructure" capabilities of Substrate:
4040

41-
1. **Instant Session Teleport:** High-performance suspend and resume of actors onto any available worker in the pool with sub-second activation.
41+
1. **Instant Actor Teleport:** High-performance suspend and resume of actors onto any available worker in the pool with sub-second activation.
4242
2. **State Persistence:** Persistent working memory (volatile RAM) and filesystem state preserved perfectly across hibernation cycles via full-state snapshots.
4343
3. **Agent Swarm Multiplexing:** Demonstrates 30x+ oversubscription by "juggling" a large registry of stateful actors onto a small pool of shared physical pods.
4444

@@ -50,7 +50,7 @@ For more videos and walkthroughs, visit our YouTube channel: **[agent-substrate]
5050

5151
Agent Substrate is designed to be **framework and agent harness agnostic**. Because it manages standard OCI containers at the kernel level (via gVisor), it can host agents built on any stack.
5252

53-
* **Agent Development Kit (ADK):** Native support for ADK-compatible session identity and persistent working memory.
53+
* **Agent Development Kit (ADK):** Native support for ADK-compatible actor identity and persistent working memory.
5454
* **LangChain:** Ideal execution environment for long-running, stateful LangChain agents and sandboxed tool-calling.
5555
* **Claude Code & CodeX:** Support for high-density, stateful coding environments that preserve terminal and filesystem state across sessions.
5656
* **Model Context Protocol (MCP):** Deploy secure, sandboxed MCP servers as Substrate Actors to provide durable tools for any LLM.
@@ -214,12 +214,19 @@ We provide several sample applications demonstrating Agent Substrate's capabilit
214214
1. **[Counter Demo](demos/counter/README.md)**: A stateful Go HTTP server demonstrating state preservation across suspends/resumes, and dynamic CRD routing.
215215
2. **[Sandbox Demo (Antigravity)](demos/sandbox/README.md)**: A secure, sandboxed execution environment (running Alpine Linux) that allows arbitrary shell execution while preserving filesystem state across sessions.
216216
3. **[Claude Code Multiplex](demos/claude-code-multiplex/README.md)**: Demonstrates oversubscribing physical hardware by multiplexing multiple Claude Code agents onto a limited pool of workers.
217+
4. **[Multi-Template](demos/multi-template/README.md)**: Two `ActorTemplate`s running different binaries share one `WorkerPool`, across three namespaces.
218+
5. **[Request Parking](demos/parking/README.md)**: An oversubscribed pool where the router holds inbound requests until a worker frees up, instead of returning `503`.
219+
6. **[Autoscaled WorkerPool](demos/autoscaled-workerpool/README.md)**: Scales a `WorkerPool` on its assigned-worker count with an HPA fed by prometheus-adapter.
217220

218221
### Documentation & Guides
222+
* [Architecture](docs/architecture.md): How the control plane, node supervisor, and networking stack fit together.
219223
* [API Configuration Guide](docs/api-guide.md): Detailed reference for configuring WorkerPools, ActorTemplates, Secrets, and Volumes.
220224
* [Full CLI Documentation](cmd/kubectl-ate/README.md): Installation and usage for `kubectl-ate`.
221-
* [Glossary](docs/glossary.md): Core terms (Actor, ActorTemplate, WorkerPool, Worker, ate-api-server, atenet, atelet, ateom) and how they relate.
225+
* [Glossary](docs/glossary.md): Core terms (Actor, Atespace, ActorTemplate, WorkerPool, Worker, ate-api-server, atenet, atelet, ateom) and how they relate.
222226
* [Observability Guide](docs/observability.md): Guide to actor logging, metrics, and distributed tracing.
227+
* [Request Parking](docs/request-parking.md): How the router parks requests through transient worker-pool saturation.
228+
* [Threat Model](docs/threat-model.md): Trust boundaries, assumptions, and known risks.
229+
* [Roadmap](docs/roadmap.md): Current limitations and what is planned next.
223230
* [Benchmarking Guide](benchmarking/README.md): Locust-based load tests, monitoring stack, and the orchestrated benchmark harness.
224231

225232
## Tour
@@ -231,8 +238,10 @@ We provide several sample applications demonstrating Agent Substrate's capabilit
231238
* `cmd/atecontroller`: A Kubernetes controller that reconciles WorkerPool and ActorTemplate custom resources.
232239
* `cmd/atenet`: A combined networking controller providing DNS, Envoy routing, and proxy sidecars.
233240
* `cmd/ateom-gvisor`: An interior-pod helper running inside sandboxed worker pods to execute `runsc` checkpoint and restore commands.
241+
* `cmd/ateom-microvm`: The micro-VM peer of `ateom-gvisor`, running actors as cloud-hypervisor VMs.
234242
* `cmd/podcertcontroller`: A "polyfill" that provides Pod Certificate signers that
235243
will eventually ship in upstream Kubernetes (with different names).
236244
* `cmd/kubectl-ate`: A CLI tool for managing Agent Substrate resources. See its [README](cmd/kubectl-ate/README.md).
245+
* `cmd/benchmarking`: Synthetic workloads used by the load tests, including `glutton`, which consumes RAM, disk, and file descriptors on demand.
237246
* `tools/setup-gcp`: A provisioning utility to set up the necessary GCP infrastructure resources (GKE, GCS, IAM).
238247
* `demos/`: Sample applications demonstrating Agent Substrate capabilities.

benchmarking/locust/common/ateapi_pb2.py

Lines changed: 115 additions & 91 deletions
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)