Esempio n. 1
0
 private void liquibaseDropAll(Application application) {
   Liquibase liquibase = null;
   try {
     liquibase = newLiquibase(application);
     liquibase.dropAll();
   } catch (ClassNotFoundException | LiquibaseException | SQLException ex) {
     throw new WervalException("Unable to drop database data: " + ex.getMessage(), ex);
   } finally {
     closeLiquibaseSilently(liquibase);
   }
 }
Esempio n. 2
0
 private void liquibaseUpdate(Application application) {
   Liquibase liquibase = null;
   try {
     liquibase = newLiquibase(application);
     liquibase.update(EMPTY);
   } catch (ClassNotFoundException | LiquibaseException | SQLException ex) {
     throw new WervalException("Unable to apply database changelog: " + ex.getMessage(), ex);
   } finally {
     closeLiquibaseSilently(liquibase);
   }
 }