HHH-4118 warn if hibernate.hbm2ddl.auto has unrecognized value
This commit is contained in:
parent
85bb1e1146
commit
fdcfeca511
|
@ -351,16 +351,19 @@ public class SettingsFactory implements Serializable {
|
||||||
if ( "validate".equals(autoSchemaExport) ) {
|
if ( "validate".equals(autoSchemaExport) ) {
|
||||||
settings.setAutoValidateSchema( true );
|
settings.setAutoValidateSchema( true );
|
||||||
}
|
}
|
||||||
if ( "update".equals(autoSchemaExport) ) {
|
else if ( "update".equals(autoSchemaExport) ) {
|
||||||
settings.setAutoUpdateSchema( true );
|
settings.setAutoUpdateSchema( true );
|
||||||
}
|
}
|
||||||
if ( "create".equals(autoSchemaExport) ) {
|
else if ( "create".equals(autoSchemaExport) ) {
|
||||||
settings.setAutoCreateSchema( true );
|
settings.setAutoCreateSchema( true );
|
||||||
}
|
}
|
||||||
if ( "create-drop".equals( autoSchemaExport ) ) {
|
else if ( "create-drop".equals( autoSchemaExport ) ) {
|
||||||
settings.setAutoCreateSchema( true );
|
settings.setAutoCreateSchema( true );
|
||||||
settings.setAutoDropSchema( true );
|
settings.setAutoDropSchema( true );
|
||||||
}
|
}
|
||||||
|
else if ( !StringHelper.isEmpty( autoSchemaExport ) ) {
|
||||||
|
LOG.warn( "Unrecognized value for \"hibernate.hbm2ddl.auto\": " + autoSchemaExport );
|
||||||
|
}
|
||||||
settings.setImportFiles( properties.getProperty( AvailableSettings.HBM2DDL_IMPORT_FILES ) );
|
settings.setImportFiles( properties.getProperty( AvailableSettings.HBM2DDL_IMPORT_FILES ) );
|
||||||
|
|
||||||
EntityMode defaultEntityMode = EntityMode.parse( properties.getProperty( AvailableSettings.DEFAULT_ENTITY_MODE ) );
|
EntityMode defaultEntityMode = EntityMode.parse( properties.getProperty( AvailableSettings.DEFAULT_ENTITY_MODE ) );
|
||||||
|
|
Loading…
Reference in New Issue