public class SchemaMigrator extends ServiceBase
| Modifier and Type | Field and Description |
|---|---|
static String |
SCHEMA_TABLE |
et, factorySvc, log| Constructor and Description |
|---|
SchemaMigrator(FactoryService factorySvc,
DBInterface dbInterface,
DTypeRegistry registry,
VarEvaluator varEvaluator) |
| Modifier and Type | Method and Description |
|---|---|
String |
calcDBFingerprint() |
List<SchemaType> |
calcDiff(List<SchemaType> list1,
List<SchemaType> list2Param) |
void |
close() |
boolean |
createSchemaTableIfNeeded() |
boolean |
dbNeedsMigration() |
MigrationPlan |
generateMigrationPlan()
dbNeedsMigration MUST have been called before this.
|
String |
getCurrentFingerprint() |
String |
getDbFingerprint() |
List<SchemaType> |
parseFingerprint(String fingeprint) |
boolean |
performMigrations(boolean doLowRiskChecks)
dbNeedsMigration MUST have been called before this.
|
boolean |
performMigrations(List<SchemaType> diffL,
boolean doLowRiskChecks) |
MigrationPlan |
runMigrationPlan(MigrationPlan plan)
dbNeedsMigration MUST have been called before this.
|
public static final String SCHEMA_TABLE
public SchemaMigrator(FactoryService factorySvc, DBInterface dbInterface, DTypeRegistry registry, VarEvaluator varEvaluator)
public void close()
public boolean createSchemaTableIfNeeded()
public boolean dbNeedsMigration()
public boolean performMigrations(boolean doLowRiskChecks)
doLowRiskChecks - whether to do additional pre-migration checkspublic MigrationPlan generateMigrationPlan()
public MigrationPlan runMigrationPlan(MigrationPlan plan)
plan - migration planpublic String calcDBFingerprint()
public List<SchemaType> parseFingerprint(String fingeprint)
public String getCurrentFingerprint()
public String getDbFingerprint()
public List<SchemaType> calcDiff(List<SchemaType> list1, List<SchemaType> list2Param)
public boolean performMigrations(List<SchemaType> diffL, boolean doLowRiskChecks)
Copyright © 2020. All rights reserved.