Skip to content

Conversation

@kimpenhaus
Copy link
Collaborator

@kimpenhaus kimpenhaus commented Oct 31, 2025

Hi Christoph @buehler ,

I've updated the k8s KubernetesClient to v18 which brings some breaking changes. Unfortunately there is no detailed changelog so I had to extract the changes by comparing v17.0.14 with v18.0.5.

Things to mention are:

  • IValidation interface was dropped - so I removed the Validation call from Transpiler/Crds.cs
image
  • Model changed from ctor arguments to property initialization

  • WatcherExt methods are marked as obsolete - but sadly the message is misleading so I have no idea yet how to replace. I will start a discussion about that with the k8s team. In the meanwhile I disabled the obsolete warning with a pragme which I will remove once I know how to chage it properly. (see: WatcherExt: Watch & WatchAsync marked as obsolete kubernetes-client/csharp#1679)

image

this will make pull request #967 obsolete

- Updated project files to use the latest version of `KubernetesClient` across the solution.
- Adjusted `Crds` logic to align with the updated library API.
…thand across tests and core classes

- Refactored entity `Metadata` and other class initializations to use object initializer shorthand consistently.
- Marked test classes as `sealed` for improved optimization and design clarity.
- Adjusted tests and core logic to align with the updated initialization style and coding standards.
- Updated object initializations across generator classes to use initializer shorthand for consistency.
- Marked generator classes as `sealed` for optimization and better design practices.
- Improved readability and alignment with modern C# coding standards.
…alizer tests

- Marked entities (`V1OperatorIntegrationTestEntity` and its sub-classes) and test classes as `sealed` for better design and optimization.
- Added null checks in finalizer integration tests to improve safety and adherence to modern C# standards.
- Disabled obsolete warning in `KubernetesClient` with a TODO for clarification.
…sts and core classes

- Updated object and dictionary initializations to improve readability.
- Applied consistent formatting to multiline constructs and private methods.
- Improved alignment with modern C# coding style.
- Adjusted formatting in `RbacGenerator` and `NamespacedOperator.Integration.Test` to enhance consistency and readability.
@buehler buehler enabled auto-merge (squash) November 7, 2025 12:26
@buehler buehler merged commit eff4af5 into dotnet:main Nov 7, 2025
3 checks passed
@kimpenhaus kimpenhaus deleted the k8s-client-v18 branch November 9, 2025 10:49
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

Successfully merging this pull request may close these issues.

2 participants