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

Quarkus 3.5.x breaks quarkus-operator-sdk #753

Closed
Jeansen opened this issue Nov 10, 2023 · 7 comments
Closed

Quarkus 3.5.x breaks quarkus-operator-sdk #753

Jeansen opened this issue Nov 10, 2023 · 7 comments

Comments

@Jeansen
Copy link

Jeansen commented Nov 10, 2023

My sandbox project builds just fine until Quarkus 3.4.3. When I bump Quarkus to 3.5.x, it no longer works.

Project: https://github.com/Jeansen/cert-operator

2023-11-10 10:11:58,782 ERROR [io.qua.dep.dev.IsolatedDevModeMain] (main) Failed to start quarkus: java.lang.RuntimeException: io.quarkus.builder.BuildException: Build failure: Build failed due to errors
	[error]: Build step io.quarkus.kubernetes.deployment.KubernetesProcessor#build threw an exception: java.lang.IncompatibleClassChangeError: Found class io.fabric8.kubernetes.api.model.rbac.ClusterRoleFluent$MetadataNested, but interface was expected
	at io.quarkiverse.operatorsdk.deployment.AddClusterRolesDecorator.createClusterRole(AddClusterRolesDecorator.java:76)
	at io.quarkiverse.operatorsdk.deployment.AddClusterRolesDecorator.lambda$visit$0(AddClusterRolesDecorator.java:36)
	at java.base/java.util.HashMap$Values.forEach(HashMap.java:1065)
	at io.quarkiverse.operatorsdk.deployment.AddClusterRolesDecorator.visit(AddClusterRolesDecorator.java:35)
	at io.quarkiverse.operatorsdk.deployment.AddClusterRolesDecorator.visit(AddClusterRolesDecorator.java:19)
	at io.fabric8.kubernetes.api.builder.Visitor.visit(Visitor.java:26)
	at io.fabric8.kubernetes.api.builder.VisitorWiretap.visit(VisitorWiretap.java:44)
	at io.fabric8.kubernetes.api.builder.BaseFluent.accept(BaseFluent.java:88)
	at io.fabric8.kubernetes.api.builder.BaseFluent.accept(BaseFluent.java:75)
	at io.fabric8.kubernetes.api.builder.BaseFluent.accept(BaseFluent.java:54)
	at io.dekorate.ResourceRegistry.lambda$generate$2(ResourceRegistry.java:181)
	at java.base/java.util.HashMap.forEach(HashMap.java:1421)
	at io.dekorate.ResourceRegistry.generate(ResourceRegistry.java:173)
	at io.dekorate.Session.generate(Session.java:293)
	at io.dekorate.Session.close(Session.java:256)
	at io.quarkus.kubernetes.deployment.KubernetesProcessor.lambda$build$2(KubernetesProcessor.java:194)
	at java.base/java.util.Optional.ifPresent(Optional.java:178)
	at io.quarkus.kubernetes.deployment.KubernetesProcessor.build(KubernetesProcessor.java:142)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.base/java.lang.reflect.Method.invoke(Method.java:568)
	at io.quarkus.deployment.ExtensionLoader$3.execute(ExtensionLoader.java:849)
	at io.quarkus.builder.BuildContext.run(BuildContext.java:282)
	at org.jboss.threads.ContextHandler$1.runWith(ContextHandler.java:18)
	at org.jboss.threads.EnhancedQueueExecutor$Task.run(EnhancedQueueExecutor.java:2513)
	at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1538)
	at java.base/java.lang.Thread.run(Thread.java:833)
	at org.jboss.threads.JBossThread.run(JBossThread.java:501)

@metacosm
Copy link
Member

metacosm commented Nov 10, 2023

Hi, the Fabric8 client was updated in Quarkus 3.5.0 and QOSDK has not yet been released to work with 3.5.x. We are actually waiting on quarkusio/quarkus#36312 because 6.8.1 and later caused some type inference issues, which hopefully should be addressed with 6.9.2. There is also another issue which breaks proper configuration support in native mode, which is fixed in the upcoming 3.6 release and which we're trying to get backported to 3.5.x if possible.

We did release 6.4.0.Beta1 which provides initial support for Quarkus 3.5.x. Give it a try and let us know how it goes!

@Jeansen
Copy link
Author

Jeansen commented Nov 11, 2023

Oh, I see. Anyway, I tried 6.4.0.Beta1 and it looks fine so far. That is, I no longer have any exceptions and my mini project works as expected again 👍 But I have not compiled to native (yet) using a full deployment including an OLM catalog. I only checked, if I could kick it off from my IDE and this worked without any issues.

@Jeansen
Copy link
Author

Jeansen commented Nov 11, 2023

Should I close this issue or should we leave it open for reference until everything is released on the stable track?

@metacosm
Copy link
Member

Let's keep this open until we have a final release for 3.5. Thank you!

@metacosm
Copy link
Member

6.4.0 has been released, closing this now.

@sorend
Copy link

sorend commented Dec 1, 2023

@metacosm Sorry for mentioning on this old ticket. I have just tried 6.4.0 and it seems there is some problem with versioning.

I do not have an in-depth analysis of the problem yet, so just mentioning it tentatively here. I believe the problem stems from:

<properties>
<quarkus.version>3.5.2</quarkus.version>
<java-operator-sdk.version>4.5.0</java-operator-sdk.version>
</properties>

Quarkus 3.5.2 brings in io.fabric8:kubernetes-client:6.8.1 while java-operator-sdk 4.5.0 wants io.fabric8:kubernetes-client:6.7.2, and I end up with something like Caused by: java.lang.NoClassDefFoundError: io.fabric8.kubernetes.client.CustomResourceFluentImpl.

@metacosm
Copy link
Member

metacosm commented Dec 2, 2023

You're right, we should have stayed with Quarkus < 3.5 for the 6.4.x series. I will release 6.4.1 soon. Note that 6.5.0 with support for Quarkus 3.6 will be released soon and you should probably move to this version once it's released as we don't plan on supporting 6.4.x once 6.5.0 is released (we will keep supporting 6.3.x, though, as it targets the LTS version of Quarkus).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants