cscetbon / casskop

This Kubernetes operator automates Cassandra operations such as deploying rack aware clusters, scaling up and down, configuring C* and its JVM, upgrading JVM and C*, backup/restores and many more...
https://cscetbon.github.io/casskop/
Apache License 2.0
13 stars 8 forks source link

Casskop doesn't work properly on Kubernetes 1.25.x #99

Closed ajoskowski closed 1 year ago

ajoskowski commented 1 year ago

Bug Report

We have deployed casskop operator on Kubernetes 1.24.x. Now we want to use it on Kubernetes 1.25.x. We are not able to do it, because casskop uses "beta" APIs - example for PodDisruptionBudget

What did you expect to see? I would like to be able to use casskop on Kubernetes 1.25.x

What did you see instead? Under which circumstances?

2023-04-05T10:53:05.629Z        INFO    controller_cassandracluster     Reconciling CassandraCluster    {"Request.Namespace": "prod-doaks-cassandra", "Request.Name": "cassandra-cluster"}
time="2023-04-05T10:53:06Z" level=error msg="CreateOrUpdatePodDisruptionBudget Error: no matches for kind \"PodDisruptionBudget\" in version \"policy/v1beta1\""
time="2023-04-05T10:53:06Z" level=error msg="ensureCassandraPodDisruptionBudget Error: no matches for kind \"PodDisruptionBudget\" in version \"policy/v1beta1\"" cluster=cassandra-cluster
time="2023-04-05T10:53:06Z" level=info msg="We will request : cassandra-cluster-dc1-rack1-0.cassandra-cluster to catch hostIdMap" cluster=cassandra-cluster err="<nil>"

Environment

Possible Solution Replace "beta" apis with stable ones

cscetbon commented 1 year ago

Thanks @ajoskowski for opening this issue. I wonder if there is somehow a way to be compatible with both. If we make this change then it won't run on older versions of k8s AFAIU ...

cscetbon commented 1 year ago

Okay it seems it's been promoted in 1.21 so I think it's safe to upgrade. @ajoskowski please create a PR

przysiadZeSztanga commented 1 year ago

Tested on kubernetes version 1.25.6 Azure AKS nad 1.25.8 GKE fyi @cscetbon

ajoskowski commented 1 year ago

@cscetbon Could you merge it?

cscetbon commented 1 year ago

Thanks @ajoskowski for your contribution !

ajoskowski commented 1 year ago

@cscetbon When do you plan to release this version?