-
Notifications
You must be signed in to change notification settings - Fork 3.1k
Description
Describe the bug
When defining a PanacheRepository outside of an entity, I get a compilation error. It seems it tries to implement the interface infinity times.
Expected behavior
The compilation suceeeds with only 1 <repository>_ class (with one underscore).
Actual behavior
I get an error:
[ERROR] COMPILATION ERROR :
[INFO] -------------------------------------------------------------
[ERROR] Problem opening file to write MetaModel for MyEntityRepository________________________________________________________________________________________________________________________________________________________________________________________________________________________________________: /Users/rokkolesa/Medius/workspaces/workspace-sandbox/panache-next-multiple-impl-bug/target/generated-sources/annotations/org/acme/MyEntityRepository_________________________________________________________________________________________________________________________________________________________________________________________________________________________________________.java: File name too long
It seems that an implementation is generated, but then that file is used to generate another one.. and so on and so on until we hit the file name length constraint.
How to Reproduce?
panache-next-multiple-impl-bug.zip
The simplest reproducer is this:
-
run
quarkus create app panache-next-multiple-impl-bug -P 3.32.2 -x=io.quarkus:quarkus-hibernate-panache-next -
Add a file
public class MyEntityRepository
implements PanacheRepository<MyEntity>
{
}- run
./mvnw clean compile
This yields the error in console. Upon checking the target, I then see this:
Output of uname -a or ver
Darwin Roks-MacBook-Pro-16.local 25.3.0 Darwin Kernel Version 25.3.0: Wed Jan 28 20:53:15 PST 2026; root:xnu-12377.81.4~5/RELEASE_ARM64_T6000 arm64
Output of java -version
openjdk version "25.0.2" 2026-01-20 OpenJDK Runtime Environment Homebrew (build 25.0.2) OpenJDK 64-Bit Server VM Homebrew (build 25.0.2, mixed mode, sharing)
Quarkus version or git rev
3.23.2
Build tool (ie. output of mvnw --version or gradlew --version)
Apache Maven 3.9.12 (848fbb4bf2d427b72bdb2471c22fced7ebd9a7a1)
Additional information
This works fine in Quarkus 3.23.1 and it seems that hibernate-orm version 7.2.5 brought in this error.
Quarkus 3.23.1 uses hibernate 7.2.4 and 3.23.2 uses hibernate 7.2.6 bringing in this error.
Metadata
Metadata
Assignees
Labels
Type
Projects
Status