Superseded by 0075: Stackra ships
packages only; services in this repository are reference apps. Decisions 1, 3, 4 and 6 carry
forward there.
Context
0011 defers Encore as the service runtime until the first service needs managed databases, pub/sub or secrets. The owner has decided the backend runs on Encore.ts, and that trigger is met. 0010 decision 6 already says that adopting Encore means one Encore application for the whole repository, but its layout (one workspace member per service atservices/<name>, each with its own entry) does not fit Encore, where an app is one
encore.app with a folder per service.
Decision
- Encore.ts is the backend runtime. The Encore row of 0011 no longer applies.
- There is one Encore application: a single
encore.appunderservices/. Its gateway is the only gateway. - One folder per Encore service inside
services/, declared by anencore.service.ts. A service never imports another service’s source; calls use the generated client or events (0015). - Packages never import
encore.dev, and apps never import a service (0003). - Workspace shape: how the single
encore.appmaps to workspace members,tier:servicetags and@stackra/service-<name>names is TODO and decided in the first-service spec. Until then 0010 decisions 1 and 5 are amended only as far as stated here. - The Encore plus legacy-decorator combination (0005) is proven by a spike before any service depends on it.
Consequences
- Managed Postgres, Pub/Sub, cron, secrets and tracing come from one platform.
- Services deploy as one unit; independent per-service deploys are given up.
- The
AGENTS.md“Not built yet” row for Encore and theservices/example,services/healthlayout need revising when this is accepted.
Enforcement
boundaries.jsonc keeps encore.dev out of packages. Planned — validate-repository.mjs check that exactly one encore.app exists and sits under services/.