Home > OS >  With Quarkus and Panache, specify the entities to use from an external library
With Quarkus and Panache, specify the entities to use from an external library

Time:11-30

The project includes multiple micro services.

All of my Panache entities are declared in their own project, and this project is included as a maven dependency in the other projects that need them. The reason they are centralised in an external library is because multiple project will use the same DB (most of them in read only).

My problem is that the lib contains all of the entities of all the projects. So any project that includes this library will create a DB containing all of the tables of all the declared entities.

How can I configure quarkus to choose which entity or which folder of entities to use instead of using every entity detected in the external lib ?

Edit - What I have tried :

  • setting quarkus.hibernate-orm.packages=my.specific.entities.package in application.properties. Result: no effect

CodePudding user response:

It was a bug in Quarkus. should be solved in v2.6 : https://github.com/quarkusio/quarkus/issues/21682

  • Related