You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/docs/operator/building-blocks/entities.mdx
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -137,7 +137,7 @@ public class EntitySpec
137
137
-`[RangeMinimum]` and `[RangeMaximum]`: Defines numeric value ranges
138
138
-`[MultipleOf]`: Specifies that a number must be a multiple of a given value
139
139
-`[Items]`: Defines minimum and maximum items for arrays
140
-
-`[UniqueItems]`: Marks an array property as requiring unique items (`uniqueItems: true`)
140
+
-`[UniqueItems]`: **Rejected by the transpiler.** Kubernetes CRD schemas do not allow `uniqueItems: true`, so applying this attribute now fails transpilation. Use `[XListType(XListType.Set)]` for Kubernetes set semantics instead
141
141
-`[PropertyLimits]`: Specifies minimum and maximum number of properties for an object
142
142
-`[ValidationRule]`: Defines custom validation rules using CEL expressions. Can be applied to properties and to class types — in both cases it emits `x-kubernetes-validations` on the corresponding schema node. When applied to both a class and a property of that type, the rules are merged (class rules first, then property rules). Class-level rules are also collected across the **class inheritance chain**: a rule placed on a base class is inherited by every derived entity or nested type, and all rules found along the chain are merged onto the schema node
The assembly inspection and attribute processing logic within this package is also leveraged by the KubeOps CLI (`kubeops generate operator`) command. The CLI uses this package's capabilities to find types decorated with `[EntityRbac]` attributes when generating the RBAC manifests (`Role`/`ClusterRole`) for your operator.
101
123
102
124
For more details on defining the C# classes themselves, see the main KubeOps documentation.
0 commit comments