Reduce dependencies of apis/CassandraDatacenter to allow newer Kubernetes #8
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Moved from datastax/cass-operator#389
When using cass-operator's CassandraDatacenter as a dependency in another project, the current implementation prevents the use of newer versions of Kubernetes dependencies (conflicts with certain removed APIs).
These dependencies come from the use of utils package as well as images. Images pulls old controller-runtime which wants old non-existant Kube APIs and the utils picks up also persistentvolume dependencies.
I think the end approach should be that apis does not call other packages inside cass-operator to ensure that it's self contained and can be more easily used in other projects as dependency. However, with these modifications I was able to use CassandraDatacenter as a dependency with Kubernetes versions up to 1.20.4 (newest released), so it solves the problem. serverconfig does not use external packages, but there was a note of code-gen requirement to keep it in the external package - which probably requires updating the controller-runtime to operator-sdk 1.x series - and that's a lot bigger project.