Skip to content

feat(apps): preserve app state in backups and legacy upgrade plans #457

Done

Description

@RentnerKev

Phase: 4 | Priority: P0

Make app versions, data and ownership recoverable and define the safe transition from built-in features.

Scope

  • Extend existing supported backup/restore to capture exact active packages/digests, data versions, app DB/files, grants and protected recovery material.

  • Add compatibility preflight for platform/engine upgrades and a durable, idempotent legacy-feature handoff framework.

  • Plan source-to-app configuration, encrypted credential and history transfer with only one productive worker owner.

  • Keep recovery available when optional apps or normal web startup fail.

  • Preserve the last-verified catalog snapshot, exact approval/package identities and required local assets in the supported recovery design. Separate cached signed trust evidence from current freshness/revocation policy and from optional Marketplace user/statistics data.

Dependencies

These are implementation prerequisites; app-to-app delivery gates do not create runtime dependencies.

Acceptance criteria

  • An isolated restore recreates the exact compatible package/data/grant set, including when remote package hosting is unavailable.
  • Database and app-file consistency is maintained; missing keys/packages, incompatible formats or partial artifacts fail safely.
  • An upgrade preview identifies configured legacy features, required app packages, active references and incompatible combinations before cutover.
  • Interrupted handoff can resume without double jobs, repeated destructive migrations or loss of user settings/history/credentials.
  • A failed app restoration or incompatible image downgrade leaves a usable maintenance/recovery path rather than reinitializing data.
  • Each extraction can plug its own migration into this framework; no direct edits to generated migration outputs or production data operations are implied by this planning issue.
  • Restore/startup works with Marketplace services stopped and package hosting unreachable when the required verified package bytes and protected recovery material are in the backup; no Marketplace login or statistics acknowledgement is needed.

Planning baseline: Beta 4.
This issue schedules future work; backlog creation does not implement or deploy it.
Use focused project checks and short integration/recovery tests. Endurance runs belong to release preparation. Normal PRs need no additional documentation files or screenshot commits unless requested.

Activity

  1. added this to the v1.0.0-beta.4 milestone on Nov 15, 2026
  2. added
    enhancement
    area: runtime
    area: database
    on Nov 15, 2026
  3. RentnerKev commented on Nov 25, 2026

    @RentnerKev
    MemberAuthor

    All acceptance criteria are covered by merged changes and tests:

    Criterion Covered by
    Isolated restore recreates the exact package, data and grant set without remote hosting #570 captures installed apps in offline CLI and Podman backups (format v6). #572 restores them offline, also over an appliance that has apps. App grants and the other app rows travel in the main database, and #564 checks each row against the installation journal before and after a restore. The privileged Greeting recovery test and the offline restore probe from #573 prove this on AMD64 and ARM64.
    Database and app-file consistency; missing keys or packages, incompatible formats and partial artifacts fail safely Portable envelope tests reject bad framing, inconsistent inventories and missing package or database members. A corrupted backup is rejected. #564 trial-decrypts every handoff part with the backed-up key and checks generations. A rejected in-place restore leaves the target unchanged (#572).
    Upgrade preview names configured legacy features, required app packages, active references and incompatible combinations #571
    Interrupted handoff resumes without double jobs, repeated destructive migrations or lost settings, history or credentials #560 (durable single-owner journal with encrypted parts), #561 (review fixes), #563 (App API v1 transport with idempotent begin and commit), #562 (workers stay stopped for handed-off domains)
    A failed app restoration or incompatible downgrade leaves a usable maintenance or recovery path #562: an older image on a newer database keeps only the proxy running and leaves the data untouched. The app image comparison checks upgrade and rollback on every pull request. An interrupted restore stays pending and resumes (#564, #572). An older app manager refuses newer app state without rewriting it, and #574 tests that the appliance then keeps the proxy and administration running.
    Each extraction plugs its own migration into the framework The handoff source registry from #560 and #563, consumed by the preview from #571. It stays empty until the first extraction registers its source.
    Restore and startup work with Marketplace services stopped and package hosting unreachable #573 restores the backup into an appliance without any network, then replaces the restored app in place.

    Not done, and optional as noted in #564: sealing downloaded backups the way off-host copies are sealed.

    Closing as completed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area: databasearea: runtimeenhancement

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions