Skip to content

Multiple datasources support [DATAJDBC-321] #544

Open
@spring-projects-issues

Description

@spring-projects-issues

Marek Šabo opened DATAJDBC-321 and commented

As mentioned in the SO answer, spring-data-jdbc currently doesn't support multiple datasources.
It would be great to add this support in future releases.

Immediate help for advanced spring users would be making JdbcRepositoryFactoryBean constructor public. That way we could provide our own dependencies based on the context of datasource.

Next step could extending the @EnableJdbcRepositories annotation with refs/links to dependencies similar way the @EnableJpaRepositories does.

(In our multi-ds JPA project we use similar configuration to one outlined in this article: https://medium.com/@joeclever/using-multiple-datasources-with-spring-boot-and-spring-data-6430b00c02e7)


Affects: 1.1 M1 (Moore), 1.0.4 (Lovelace SR4)

Reference URL: https://stackoverflow.com/a/50197148/303559

Issue Links:

  • DATAJDBC-499 Register custom converters in two independent modules
    ("is duplicated by")
  • DATAJDBC-622 Add support for transactionManagerRef in EnableJdbcRepository

14 votes, 15 watchers

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions