| This finally will be doable as of ORM 5.1 with the required changes implemented as part of HHH-10458. What we'll have to do:
- Implement an OGM-specific SchemaManagementTool and its delegates
- Drop properties "hibernate.ogm.datastore.create_database" (replaced by "hbm2ddl.auto") and likely "hibernate.ogm.datastore.database" (I suppose "hibernate.default_schema" can be used instead)
- Add support for dropping tables etc. -> add List<T> getDropCommands() to SchemaDefiner where <T> is a store-specific type of DDL commands (mostly String, but it may be some object representation e.g. for MongoDB which does not have a DDL)
- The schema management mechanism supports different types of "targets": DATABASE, SCRIPT and STDOUT; In a first step OGM would only support the former; Naturally, the other two require DDL commands to have a String-assignable representation, so they may not be doable for some backends
- Further steps will include
- Support for reading import scripts (SourceType.SCRIPT etc.); Again the String-requirement may make it not supportable for some stores
- Support for the other hbm2ddl modes (validation, migration)
|