When any liquibase exception is thrown and it catches in LiquibaseJpaUpdaterProvider update method inside try\catch block, an exception will be retrown like RuntimeException, but it will not be logged anywhere. It reaches platform.exit(t) and then only message of wrapped RuntimeException is propagated. But real caused can be noticed only via debug mode.

This commit is contained in:
kurisumakise2011 2020-06-05 19:57:36 +03:00 committed by Hynek Mlnařík
parent 5c2385d081
commit bfde3ac080

View file

@ -113,6 +113,7 @@ public class LiquibaseJpaUpdaterProvider implements JpaUpdaterProvider {
}
}
} catch (LiquibaseException | IOException | SQLException e) {
logger.error("Error has occurred while updating the database", e);
throw new RuntimeException("Failed to update database", e);
} finally {
ThreadLocalSessionContext.removeCurrentSession();