
Ability to integrate into already existing Databases
theneedforsneed opened this issue ยท 2 comments
As far as I know, MyWarp requires that MySQL databases be empty before data will be stored in them.
On shared databases it is recommended to use a dedicated schema for MyWarp, and for MyWarp only.
- MyWarp Wiki, Warp Storage
We currently use the built in H2 flat file database, but I'd love to move it to our dedicated MySQL server. However, we are unable to secure another MySQL database as our server is hosted through a hosting company.
After a quick look around, I noticed Flyway has a Baseline section that might be able to allow MyWarp to use a pre-existing database.
http://flywaydb.org/documentation/command/baseline.html
Is there any way to implement this?
After some thinking, I think that an option to disable FlyWay entirely would do more harm than good.
As argued, hosting companies that only allow a single MySQL scheme are somewhat unprofessional. Since this is by no means a standard, I think it is a fair burden to require usage of H2 (or SQLite) in such cases, both are fine relational databases after all.
Sorry for the delay, I was on vacation without proper internet access.
Unfortunately it is technically impossible to integrate FlyWay with existing databases without also controlling these databases. The baseline-functionality is meant to baseline existing databases; that is, to assign existing databases to a version within FlyWay's version-control-logic. This means that DDL and data of the databases must be available for FlyWay and that all further changes are done via FlyWay only. Both points are unrealistic when it comes to MyWarp.
The only realistic way to allow usage with existing databases is to provide an option to disable FlyWay and table creation entirely. Though this is somewhat problematic because if a server admin misses a required update, the database could be massively messed up.
However, as a server admin, I would argue that a hosting company that only allows usage of a single MySQL scheme is somewhat unprofessional.