Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multiple QuarkusApplicationClassBuildItem #38553

Open
CodeSimcoe opened this issue Feb 2, 2024 · 0 comments
Open

Multiple QuarkusApplicationClassBuildItem #38553

CodeSimcoe opened this issue Feb 2, 2024 · 0 comments
Labels
kind/enhancement New feature or request

Comments

@CodeSimcoe
Copy link

CodeSimcoe commented Feb 2, 2024

Description

Hello,

It is currently not possible to produce multiple QuarkusApplicationClassBuildItem.
That rather makes sense.

But from my understanding it is based on a declarative basis, not an effective one.

Example :
I have 2 extensions that declare a production of such an item, but do not effectively produce it.
Still, build is in error.

Code example
https://github.com/CodeSimcoe/quarkus-main-clash

Real world need :
I am trying to use both picocli and a custom QuarkusApplication (for JavaFX needs).
Even if picocli does not effectively produce its QuarkusApplicationClassBuildItem if a @QuarkusMain is found within the application, the build is in error, as shown in my example.

[ERROR] Failed to execute goal io.quarkus.platform:quarkus-maven-plugin:3.7.1:build (default) on project code-with-quarkus: Failed to build quarkus application: io.quarkus.builder.Ch
ainBuildException: Multiple producers of item class io.quarkus.deployment.builditem.QuarkusApplicationClassBuildItem (io.quarkus.my.ext.a.deployment.MyExtAProcessor#mainProducer): Th
is is the location of the conflicting producer (io.quarkus.my.ext.b.deployment.MyExtBProcessor#mainProducer)

I don't know if making QuarkusApplicationClassBuildItem a MultiBuildItem makes any sense, but maybe if there is no effective production like in my example, it shall build.

Thanks

Implementation ideas

No response

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants