docs/reference/control-plane-api.md sections 5.5, 5.11 and 5.13. Code:
internal/controlplane/lifecycle. Every action is an operator route: a
console session of a user whose GitHub id is in OPERATOR_GITHUB_IDS
(operators.md).
Suspending a project
Suspension stops ingestion and keeps everything else: use it while a question about a project is open (traffic that looks forged, a project that may not be part of the ecosystem, an abuse report), or as the reversible first step before removal.-
In the console operator area open the project and choose Suspend, or
call
POST /api/operator/tenants/{tenant_id}/suspendwith{"reason": "..."}. The reason is required and the project’s members see it. Only anactiveproject can be suspended; anything else answers409 invalid_transitionwith the current status. -
In one transaction the status becomes
suspendedwith an audit row (tenant.suspend), then the reconciler switches the project’s entries in theregistry_sitesandregistry_otlpbuckets tosuspended. From then on the gateways refuse the project’s web events and the collectors refuse its OTLP tokens. Refusals are counted, so the project’s ingest view shows them. - The Umami dashboards stay readable for the members. Data already stored stays. Members see the status and reason in the console.
-
Check it took effect:
(run on the leader as in overview.md). The gateway’s refusal of a suspended site is
rejected_inactive_siteincp.web_ingest_hourly.
POST /api/operator/tenants/{tenant_id}/resume
(reason optional). The registry entries switch back to active and
ingestion restarts. Events sent while suspended were refused, not queued, and
do not come back.
Open question for SCF
After removal, are the anonymous daily aggregates of a project deleted or kept? SCF has not answered yet.- Default (the answer assumed until SCF decides): deleted.
- Setting:
removal_keep_aggregatesincp.settings, changed by an operator withPUT /api/operator/settings/removal-keep-aggregates({"keep": true}). Every change is in the audit log assettings.removal_keep_aggregates. - The value is copied into
cp.tenant_removals.keep_aggregatesat the moment a project is removed. Changing the setting later never changes a removal that already started. keep = truekeepscp.web_ingest_hourlyrows and, from phase 11, theaggrows of the project. Umami websites with their raw events, and from phase 9 theapiminute rows, are always deleted.
Removing a project
-
In the console operator area, open the project and choose Remove, or
call
POST /api/operator/tenants/{tenant_id}/removewith{"reason": "..."}. The reason is required and the project’s members see it. -
In one transaction the control plane sets the project to
removed, sets every site toremoved(domains stay on the rows), deletes open invites, inserts thecp.tenant_removalsrow and writes thetenant.removeaudit row. -
The reconciler then purges, store by store, in this order. Ingestion stops
first, data goes after:
Each finished step is stored in
cp.tenant_removals.stepsand audited aspurge.step(actorsystem:purge). When every step is done,completed_atis set andpurge.completeis written. -
The project row, its member rows and every audit row remain. Former
members get 404 on every project route;
/api/melists the project underremoved_tenantswith the reason.
open mode.
Following a removal
removal in
GET /api/operator/tenants/{tenant_id} and in GET /api/operator/audit?tenant_id=<id>.
A step that keeps failing
A failed step is retried on every reconcile (after each change, and by thejobs task reconcile every 10 minutes). Later steps wait for it. The error
is in the control plane or jobs log with the step name and tenant id.
umami website ... belongs to team ...: an Umami website with the site’s id belongs to another team. Do not delete it blindly: find out why the ids clash, then delete or move it by hand and let the next reconcile continue.- Umami or NATS unreachable: nothing to do once they are back.
removed tenant has no cp.tenant_removals row: the status was set toremovedby hand in the database. Removal must go through the operator api. Set the previous status back and remove the project through the api.
Exercised
Not yet exercised by a person through the console of a deployed
environment: no staging exists. The SCF answer on whether aggregates are kept
after removal is still open (section above).