flyway/flyway — pull request #629 by bjhartin (2013-10-18 14:17:31+00:00)
Title: Custom dbsupport classes

Hi Axel,

This supports extending Flyway's DbSupport classes via a simple property, e.g.

flyway.dbsupport.H2=org.myorganization.OurH2DbSupport

I wrote this because my company has run into several issues with object types that Flyway doesn't clean. I see your issue tracker has quite a few such requests. This would allow me to extend SqlServerSchema to override 'doClean'. I think this will save you some work because I see a lot of issues of the form "Flyway doesn't clean object type T for database vendor D." You could now simply suggest they write extensions. See CustomCleanTest for an example of how this would work.

I also added some test coverage for DbSupportFactory.

In addition, I think this resolves a mismatch in the clean/migrate approach, in that I can _create_ anything I want in a migration script but I can only _drop_ the things that Flyway specifically knows about.

Thanks for your consideration,

Brian Hartin