docs/api/exposed-spring-boot4-starter/org.jetbrains.exposed.v1.spring.boot4.autoconfigure/-exposed-auto-configuration/index.html
@AutoConfiguration(after = [DataSourceAutoConfiguration::class])
@EnableTransactionManagement
open class ExposedAutoConfiguration(applicationContext: ApplicationContext)
Main configuration class for Exposed that can be automatically applied by Spring Boot.
This should be applied on a Spring configuration class using: @ImportAutoConfiguration(ExposedAutoConfiguration::class)
Note As part of the configuration, @EnableTransactionManagement is added without setting any attributes. This means that all attributes have their default values, including mode = AdviceMode.PROXY and proxyTargetClass = false. If the type of proxy mechanism is unexpected, the attributes can be set to the required values in a separate @EnableTransactionManagement on the main configuration class or in a configuration file using spring.aop.proxy-target-class.
Members
Link copied to clipboard
constructor(applicationContext: ApplicationContext)
Link copied to clipboard
@Bean
@ConditionalOnMissingBean(value = [DatabaseConfig::class])
open fun databaseConfig(): DatabaseConfig
Database config with default values
Link copied to clipboard
@Bean
@ConditionalOnProperty(value = ["spring.exposed.generate-ddl"], havingValue = "true", matchIfMissing = false)
open fun databaseInitializer(): DatabaseInitializer
Returns a DatabaseInitializer that auto-creates the database schema, if enabled by the property spring.exposed.generate-ddl in the application.properties file.
exposedSpringTransactionAttributeSource
Link copied to clipboard
@Bean
@Primary
open fun exposedSpringTransactionAttributeSource(): ExposedSpringTransactionAttributeSource
Returns an ExposedSpringTransactionAttributeSource instance.
Link copied to clipboard
@Bean
open fun springTransactionManager(datasource: DataSource, databaseConfig: DatabaseConfig): SpringTransactionManager
Returns a SpringTransactionManager instance using the specified datasource and databaseConfig.
Generated by Dokka © 2026 Copyright