State-based approach
Published 08 August 2022
Model name: | State-based dev and state-based deployment | ||
---|---|---|---|
Model description: | The source of truth of the dev DB state is the schema model, which is used as the "desired state" for both the purposes of sharing changes within the team and as a source for deployment. The deployment script is generated at deployment time by Flyway's comparison engine. Note that there are complex changes that cannot be inferred by a comparison engine, such as applying NOT NULL columns without a DEFAULT to tables that contain data, and other changes that require data to be moved or transformed. The state-based deployment model is suitable for
| ||
Required editions | Flyway Community | Flyway Teams | Flyway Enterprise |
Authoring migrations | N/A | Not required as schema model is the source of deployments | Not required as schema model is the source of deployments |
Sharing changes in dedicated development databases | N/A | Changes shared using schema model | Changes shared using schema model |
Database CI/CD | N/A | Not supported | Flyway checks available |
Database Deployment | N/A | Manual state-based deployments allowed | Automated state-based deployments allowed |