App lifecycle
This page describes how an App install and update from a repository, and what uninstalling means for the App’s data. Repository setup and the Instance-to-repository API are described on App repositories and stores; package contents are described on App package.
Install
- The package is loaded from configured repositories and the signature is always checked. Sideloading is not a production install path; a development-only local workflow may be considered later.
- The Instance admin uses the Host’s install-management UI/API to browse available or installed packages across repositories, select a repository and package, review requested capabilities and rationales, and approve installation. This is the admin-to-Instance interface; the Host separately fetches metadata and artifacts through the selected repository API.
- At install/update, the admin may disable capabilities or tighten their parameters. Accounts may tighten these settings but cannot widen them. Admin approval of capabilities does not grant Dataset access. Owners separately create Dataset Grants.
- The Host verifies the release, assigns an opaque install id, records the source and package id binding, and reads the static manifest. There is one code install per package binding. The installation remains pinned to that source for updates.
Update without migration
- The Host polls the pinned source and offers an admin check-now action. The admin approves an update. Optional automatic updates are allowed only when no migration cutover is required.
- Verify the new package before use. The old and new module generations can coexist until old sessions drain; old sessions and their events continue on the old generation.
- Package rollback is allowed only if no data migration has occurred.
Update with migration
A kind version change or breaking event shape requires a manifest migration plan authored by the App. If a kind is bumped without a plan, the Host refuses dual-generation operation.
Migration is a single explicit cutover and is never applied automatically:
- Pause the App. Its Externals are queued or unavailable while Grants are retained.
- Take a mandatory Host backup.
- Run the App-authored ordered migration steps.
- Switch to the new generation and re-check Views.
If migration fails, abort and restore the backup; do not run the new generation against partially migrated data. After a successful migration, recovery is by backup/restore, not package rollback. Open question: what if more than one App uses a DataSource?
Uninstall and reinstall
- Uninstall is admin-only. The Host revokes Grants to that install but Datasets remain.
- When no App or External Grants remain for a Dataset, mark it stale, show it in the Shell overview, and notify its Owners. Owners decide whether to retain, rejoin, or remove the data.
- Reinstalling creates a new install id. Rejoining existing data uses a user-mediated capability-granting mechanism; it is a clean install, not restoration of the previous install identity.