Package com.onec.schema
Class SchemaMigrator
java.lang.Object
com.onec.schema.SchemaMigrator
Additive-only schema evolution: adds columns that exist in the metadata model but not in
the live database. Never renames, retypes or drops anything — for that, see
SchemaUpgrader, which subsumes this as part of its plan.
A column declared required is added nullable, backfilled with a neutral value,
and only then constrained NOT NULL — adding it constrained in one step would fail
on any table that already has rows (see DdlRenderer.addColumn(java.lang.String, com.onec.schema.ColumnModel)).
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidexecuteAdditive(org.jdbi.v3.core.Jdbi jdbi) generateAdditiveDDL(org.jdbi.v3.core.Jdbi jdbi)
-
Constructor Details
-
SchemaMigrator
-
-
Method Details
-
generateAdditiveDDL
-
executeAdditive
public void executeAdditive(org.jdbi.v3.core.Jdbi jdbi)
-