controller-tools currently allows both:
+required / +optional
+kubebuilder:validation:Required / +kubebuilder:validation:Optional
These perform the same function. Maintaining both causes confusion and inconsistent API definitions.
Proposal:
- Deprecate
+kubebuilder:validation:Required and +kubebuilder:validation:Optional
- Recommend
+required and +optional
- (Optional) Warn when deprecated markers are used
Motivation, context came from: kubernetes-sigs/kube-api-linter#112