Skip to content

Commit

Permalink
Document configuration when using Spring starter (#1654)
Browse files Browse the repository at this point in the history
  • Loading branch information
Kantis committed Jan 16, 2023
1 parent 4a9d718 commit 6b367af
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions exposed-spring-boot-starter/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,21 @@ spring.datasource.username=sa
spring.datasource.password=password
```

### Configuring Exposed
When using this starter, you can customize typical Exposed configuration by registering a [DatabaseConfig](https://github.com/JetBrains/Exposed/blob/master/exposed-core/src/main/kotlin/org/jetbrains/exposed/sql/DatabaseConfig.kt). See the class itself for available configuration options.

Example:

```kotlin
@Configuration
class ExposedConfig {
@Bean
fun databaseConfig() = DatabaseConfig {
useNestedTransactions = true
}
}
```

## Automatic Schema Creation
This starter will create the database schema if enabled automatically using any class that extends `org.jetbrains.exposed.sql.Table`

Expand Down

0 comments on commit 6b367af

Please sign in to comment.