Skip to content

EntityManagerFactoryBuilder cannot be used as advertised #10068

Closed
@odrotbohm

Description

@odrotbohm

The reference documentation suggests to use EntityManagerFactoryBuilder to setup EntityManagerFactory instances in case one has to configure multiple ones. Unfortunately, the code shown doesn't work as the EMFB bean is created by JpaAutoConfiguration which expects a singular DataSource instance in the first place. Manually excluding that configuration then results in the EMFB not being present and the invocation of the factory method failing.

Maybe the auto-configuration for EMFB can be moved to a separate class that is not dependent on a single DataSource instance?

Related tickets: #5542, #5541.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions