Dense-Mem
← Running and verifying Dense-Mem

Upgrade a database safely

Follow a startup upgrade while the previous notes keep their source history.

Coordinate the upgrade

  1. First server

    Applying schema upgrade

  2. Second server

    Waiting for the database lock

Two server instances start against the same database. One waits while the other applies the upgrade.

  1. Startup runner

    Acquire migration lock

  2. Shared database

    Apply the next version

  3. Waiting starter

    Continue after compatible state

The migration runner serializes startup schema work at the writable primary. Traffic remains gated until required checks pass.

migration versioninteger
Ordered Goose migration
20261110010000
Startup migration runner and history
20261110010000

The version identifies the Evidence-only cutover. Startup applies a pending version in order and uses the migration history to distinguish completed work.

statusstring
GET /ready · dependency check result
"ready"
Deployment health check
"ready"

Required dependencies must pass before the readiness endpoint reports ready. A failed essential check keeps a new instance out of traffic.

Keep the original sources

  1. Original Evidence

    We rehearse in Room 4.

  2. Derived topics

    Rebuild after startup

The rehearsal note and its source are still available after the upgrade.

  1. Protected canonical data

    Retain Evidence and provenance

  2. Derived organization

    Reset as part of the pending version

  3. Worker

    Rebuild from eligible shared notes

The Evidence-only cutover retains original Evidence and clears its derived organization under the explicit migration inventory. Later maintenance can rebuild topics.

migration versioninteger
Ordered Goose migration
20261110010000
Startup migration runner and history
20261110010000

The version identifies the Evidence-only cutover. Startup applies a pending version in order and uses the migration history to distinguish completed work.

occurrences[0].partition.source_item_idUUID
Trace · recorded occurrence
"20000000-0000-4000-8000-000000000002"
Original submitted item
"20000000-0000-4000-8000-000000000002"

The occurrence’s partition points to the original item. Its stored bounds locate the slice inside that item.

trace_memory result · Required · Up to 128 characters

Read the reference