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

Compatibility Issue with josdk-webhooks and Fabric8 Kubernetes Client #309

Closed
ebma16 opened this issue Dec 13, 2024 · 6 comments
Closed

Comments

@ebma16
Copy link

ebma16 commented Dec 13, 2024

Hi,

I attempted to locally update josdk-webhooks to use fabric8:kubernetes-client v7.0.0 to ensure compatibility with the new beta release of java-operator-sdk. However, I encountered an issue where the tests for the Quarkus part of the project are failing.

From what I’ve observed, the root cause seems to be that josdk-webhooks cannot currently be updated to fabric8:kubernetes-client v7.0.0 because Quarkus includes its own dependency on fabric8, which still references fabric8:kubernetes-client v6.13.4 on the latest officially released version.

Can you confirm that the josdk-webhooks framework won't be updated/released until Quarkus is updated to fabric8:kubernetes-client v7.0.0 with quarkusio/quarkus#42335?

Thank's for you feedback!

Kind regards
Martin

@csviri
Copy link
Contributor

csviri commented Dec 13, 2024

Hi @ebma16 , not necessarily, we have to discuss can skip quarkus releasing, until it catching up with with fabric8 7.0. Or do you see any other possibility @metacosm ?

@afalhambra-hivemq
Copy link

Hello,
Not completely sure if it's related to the same issue but we're currently testing out our operator to update it to the latest JOSDK 5.0.0 RC1. However we are also facing an incompatibility issue as well here when it comes to the josdk-webhooks version 1.1.6 and using the Fabric8 Kubernetes version 7.0.1.
To be precise, the getTargetResource method in the AdmissionUtils class is trying to call a method getObject on the AdmissionRequest class from the Fabric8 Kubernetes client whose signature has changed and no longer returns a KubernetesResource but an Object instead. Thus, this fails in runtime with the following error:

java.lang.NoSuchMethodError: 'io.fabric8.kubernetes.api.model.KubernetesResource io.fabric8.kubernetes.api.model.admission.v1.AdmissionRequest.getObject()'
	at io.javaoperatorsdk.webhook.admission.AdmissionUtils.getTargetResource(AdmissionUtils.java:37)
	at io.javaoperatorsdk.webhook.admission.mutation.DefaultAdmissionRequestMutator.handle(DefaultAdmissionRequestMutator.java:35)
	at io.javaoperatorsdk.webhook.admission.AdmissionController.handle(AdmissionController.java:27)
	at com.hivemq.platform.operator.webserver.AdmissionHandler.handle(AdmissionHandler.java:73)
	at org.eclipse.jetty.server.Handler$Sequence.handle(Handler.java:805)
	at org.eclipse.jetty.server.Server.handle(Server.java:182)
	at org.eclipse.jetty.server.internal.HttpChannelState$HandlerInvoker.run(HttpChannelState.java:662)
	at org.eclipse.jetty.server.internal.HttpConnection.onFillable(HttpConnection.java:418)
	at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:322)
	at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:99)
	at org.eclipse.jetty.io.SelectableChannelEndPoint$1.run(SelectableChannelEndPoint.java:53)
	at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:979)
	at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.doRunJob(QueuedThreadPool.java:1209)
	at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:1164)
	at java.base/java.lang.Thread.run(Thread.java:1583)

@csviri
Copy link
Contributor

csviri commented Jan 28, 2025

Hi @afalhambra-hivemq , we will release a new version of webhook after josdk is released, where the fabric8 client versions will be synced, and this issue will go away.

@afalhambra-hivemq
Copy link

Thanks @csviri - is there any ETA for that?

@csviri
Copy link
Contributor

csviri commented Jan 28, 2025

hopefully JOSDK + QOSDK will be released next week, shortly after will try to do this.

@csviri
Copy link
Contributor

csviri commented Feb 3, 2025

Hi, I've just released the new version (2.0.0) that uses the newest fabric8 client. Closing this issue.

@csviri csviri closed this as completed Feb 3, 2025
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