public class ConfigurableLocalSessionFactoryBean
extends org.springframework.orm.hibernate5.LocalSessionFactoryBean
LocalSessionFactoryBean
which changes how Hibernate is configured.Constructor and Description |
---|
ConfigurableLocalSessionFactoryBean(Function<DataSource,net.sf.hibernate.connection.ConnectionProvider> connectionProviderSupplier) |
Modifier and Type | Method and Description |
---|---|
void |
afterPropertiesSet() |
protected org.hibernate.SessionFactory |
buildSessionFactory(org.springframework.orm.hibernate5.LocalSessionFactoryBuilder config) |
static void |
configureHibernateSystem() |
Iterable<String> |
getCurrentMappingResources() |
MappingResources |
getMappingResources()
Deprecated.
since 5.6, use
getCurrentMappingResources() |
static org.hibernate.boot.Metadata |
getMetadata(org.hibernate.cfg.Configuration config)
Get the Metadata object that defines the database schema.
|
protected void |
prepareConfiguration(org.hibernate.cfg.Configuration config)
This method is called after the Configuration object has been created and
before the SessionFactory has been created.
|
void |
setCurrentMappingResources(Iterable<String> mappingResources) |
void |
setDataSource(DataSource dataSource) |
void |
setHibernateConfig(com.atlassian.config.db.HibernateConfig hibernateConfig) |
void |
setLobHandler(org.springframework.jdbc.support.lob.LobHandler lobHandler) |
void |
setMappingResources(MappingResources mappingResources)
Deprecated.
since 5.6, use
setCurrentMappingResources(Iterable) |
destroy, getConfiguration, getHibernateProperties, getMetadataSources, getObject, getObjectType, getResourceLoader, isSingleton, setAnnotatedClasses, setAnnotatedPackages, setBootstrapExecutor, setCacheableMappingLocations, setConfigLocation, setConfigLocations, setCurrentTenantIdentifierResolver, setEntityInterceptor, setEntityTypeFilters, setHibernateProperties, setImplicitNamingStrategy, setJtaTransactionManager, setMappingDirectoryLocations, setMappingJarLocations, setMappingLocations, setMappingResources, setMetadataSources, setMultiTenantConnectionProvider, setPackagesToScan, setPhysicalNamingStrategy, setResourceLoader
public ConfigurableLocalSessionFactoryBean(@Nonnull Function<DataSource,net.sf.hibernate.connection.ConnectionProvider> connectionProviderSupplier)
public static void configureHibernateSystem()
@Deprecated public MappingResources getMappingResources()
getCurrentMappingResources()
public void setHibernateConfig(com.atlassian.config.db.HibernateConfig hibernateConfig)
@Deprecated public void setMappingResources(MappingResources mappingResources)
setCurrentMappingResources(Iterable)
mappingResources
- The mappingResources to set.public void setCurrentMappingResources(Iterable<String> mappingResources)
public void setLobHandler(org.springframework.jdbc.support.lob.LobHandler lobHandler)
public void setDataSource(DataSource dataSource)
setDataSource
in class org.springframework.orm.hibernate5.LocalSessionFactoryBean
public static org.hibernate.boot.Metadata getMetadata(org.hibernate.cfg.Configuration config)
public void afterPropertiesSet() throws IOException
afterPropertiesSet
in interface org.springframework.beans.factory.InitializingBean
afterPropertiesSet
in class org.springframework.orm.hibernate5.LocalSessionFactoryBean
IOException
protected org.hibernate.SessionFactory buildSessionFactory(org.springframework.orm.hibernate5.LocalSessionFactoryBuilder config)
buildSessionFactory
in class org.springframework.orm.hibernate5.LocalSessionFactoryBean
protected void prepareConfiguration(org.hibernate.cfg.Configuration config)
Copyright © 2003–2017 Atlassian. All rights reserved.