-
Notifications
You must be signed in to change notification settings - Fork 41.4k
Open
Labels
status: pending-design-workNeeds design work before any code can be developedNeeds design work before any code can be developedtype: enhancementA general enhancementA general enhancement
Milestone
Description
Auto-configuration of a single DataSource works well for the vast majority of users, but when a subsequent DataSource is required things get harder (see #7652 for one example) as all of the data sources then need to be manually configured. We'd like to make things easier by providing support for auto-configuring multiple DataSources. In terms of properties, this could look something like this:
spring.datasource.primary.url=…
spring.datasource.primary.username=…
spring.datasource.primary.password=…
spring.datasource.secondary.url=…
spring.datasource.secondary.username=…
spring.datasource.secondary.password=…
Some more design work is needed, but primary
could be used as a "special" name that results in the auto-configured bean being marked as @Primary
. We'd also need similar functionality for components that consume a DataSource
such as JPA, transaction management, Flyway and Liquibase.
jmmut, jorizci, oursy, OrangeDog, tkvangorder and 35 more
Metadata
Metadata
Assignees
Labels
status: pending-design-workNeeds design work before any code can be developedNeeds design work before any code can be developedtype: enhancementA general enhancementA general enhancement