Primitives
Deploy, distribute, push, connect, expose and observe — the six primitives under design.
Design draft. The notation below is illustrative. It is not a released API and will change.
The framework concept is organized around six primitives. Each expresses one intention and absorbs the work that intention normally requires.
| Primitive | Intention | Absorbs |
|---|---|---|
deploy | Run this service in an environment | Build pipelines, environments, secrets, rollbacks, health checks |
distribute | Deliver these assets and versions | CDN rules, cache invalidation, artifact versioning, regions |
push | Deliver this message to these clients | Device tokens, fan-out, retries, delivery receipts, rate limits |
connect | Let these services talk | Discovery, service authentication, queues, timeouts, schemas |
expose | Publish this API | Routing, validation, rate limiting, documentation, versioning |
observe | Tell me how it is doing | Metrics, logs, traces, alerts, backups |
Illustrative notation
The sketch below shows the shape of intent we are designing for — a declarative description of a small system.
// Concept notation — not a released API.
const system = framework.system("orders", {
services: {
api: deploy({ from: "./services/api", env: ["production", "staging"] }),
worker: deploy({ from: "./services/worker" }),
},
apis: {
public: expose("api", { version: "v1", rateLimit: "100/min" }),
},
links: [connect("api", "worker", { via: "queue" })],
delivery: distribute("./web/dist", { cache: "immutable" }),
notifications: push({ channels: ["ios", "android", "web"] }),
operations: observe({ alerts: "on-call", backups: "daily" }),
});Principles applied to every primitive
- Defaults are safe. TLS everywhere, least-privilege credentials, encrypted backups.
- Defaults are visible. Every primitive reports what it did and why.
- Everything can be overridden. A primitive can be replaced by explicit configuration at any layer.