How to upgrade Orion instance to use the latest release?

Follow these steps:

  1. Upgrade pip package: pip install -U "prefect>=2.0b"
  2. Restart Orion: prefect start orion

Under the hood when the Orion API server is restarted, it automatically runs database migrations for you on app startup as part of lifecycle management. This is valid for both ephemeral SQLite and persistent Postgres databases.

How to disable automatic migration?

You can set PREFECT_ORION_DATABASE_MIGRATE_ON_START to False

Troubleshooting upgrades

If something didn’t work as expected, you can run DB migration manually using prefect orion database upgrade.