HHH-14047 Allow customization of the StandardServiceRegistryBuilder by extending the EntityManagerFactoryBuilderImpl
This commit is contained in:
parent
d7373a86bb
commit
76e305ba75
|
@ -212,7 +212,7 @@ public class EntityManagerFactoryBuilderImpl implements EntityManagerFactoryBuil
|
||||||
);
|
);
|
||||||
|
|
||||||
// merge configuration sources and build the "standard" service registry
|
// merge configuration sources and build the "standard" service registry
|
||||||
final StandardServiceRegistryBuilder ssrBuilder = StandardServiceRegistryBuilder.forJpa( bsr );
|
final StandardServiceRegistryBuilder ssrBuilder = getStandardServiceRegistryBuilder( bsr );
|
||||||
|
|
||||||
final MergedSettings mergedSettings = mergeSettings( persistenceUnit, integrationSettings, ssrBuilder );
|
final MergedSettings mergedSettings = mergeSettings( persistenceUnit, integrationSettings, ssrBuilder );
|
||||||
|
|
||||||
|
@ -280,6 +280,13 @@ public class EntityManagerFactoryBuilderImpl implements EntityManagerFactoryBuil
|
||||||
metamodelBuilder.applyTempClassLoader( null );
|
metamodelBuilder.applyTempClassLoader( null );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Extension point for subclasses. Used by Hibernate Reactive
|
||||||
|
*/
|
||||||
|
protected StandardServiceRegistryBuilder getStandardServiceRegistryBuilder(BootstrapServiceRegistry bsr) {
|
||||||
|
return StandardServiceRegistryBuilder.forJpa( bsr );
|
||||||
|
}
|
||||||
|
|
||||||
private void applyMetadataBuilderContributor() {
|
private void applyMetadataBuilderContributor() {
|
||||||
|
|
||||||
Object metadataBuilderContributorSetting = configurationValues.get( METADATA_BUILDER_CONTRIBUTOR );
|
Object metadataBuilderContributorSetting = configurationValues.get( METADATA_BUILDER_CONTRIBUTOR );
|
||||||
|
|
Loading…
Reference in New Issue