Class DatabaseSchemaPopulator

java.lang.Object
org.springframework.jdbc.datasource.init.CompositeDatabasePopulator
ubic.gemma.persistence.initialization.DatabaseSchemaPopulator
All Implemented Interfaces:
org.springframework.jdbc.datasource.init.DatabasePopulator

public class DatabaseSchemaPopulator extends org.springframework.jdbc.datasource.init.CompositeDatabasePopulator
Populates the database schema.

Renovations Phase 2: previously took a LocalSessionFactoryBean to pull a Hibernate Configuration for DDL generation. That path is gone — Hibernate 6 builds the schema via org.hibernate.tool.schema.spi.SchemaCreator (driven from MetadataSources) and Spring's wiring is JPA-based. Production schemas come from gemma-core/src/main/resources/sql/migrations/*.sql (applied by the DBA), so the Hibernate-DDL portion of this populator is a no-op; tests rely on the JPA EMF's hibernate.hbm2ddl.auto=create property instead.

Author:
poirigui
  • Constructor Details

    • DatabaseSchemaPopulator

      public DatabaseSchemaPopulator(String vendor)