liquibase/liquibase — pull request #304 by djmorton42 (2014-08-24 18:10:21+00:00)
Title: CORE-2014 applyToRollback attribute of modifySql not respected when rollback element included in changeset

modifySql attribute applyToRollback is ignored when specific rollback steps are included in a changeset. Modified behavior of Rollback to ensure that with either custom rollback steps or automatically generated rollback statements, modifySql elements are not applied to the rollback SQL if the applyToRollback is false.

This included refactoring small amounts of the ChangeSet.java and AbstractJdbcDatabase.java file to centralize the Rollback statement execution code. Rather than call the ExecutorService.execute method in the ChangeSet.java file when dealing with custom SQL rollback steps, a new overload of executeRollbackStatements in AbstractJdbcDatabase.java is called which takes the list of custom statements to execute. Then, filtering of the SqlVisitors is done consistently both for custom rollback steps and automatically generated ones.