Skip to content

Commit

Permalink
Fix CRD CEL transition rule error message example
Browse files Browse the repository at this point in the history
Signed-off-by: Stefan Büringer [email protected]
  • Loading branch information
sbueringer committed Jun 28, 2024
1 parent 5ea6ba0 commit 5904467
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1247,8 +1247,7 @@ Unlike other rules, transition rules apply only to operations meeting the follow
later update to the same object.

Errors will be generated on CRD writes if a schema node contains a transition rule that can never be
applied, e.g. "*path*: update rule *rule* cannot be set on schema because the schema or its parent
schema is not mergeable".
applied, e.g. "oldSelf cannot be used on the uncorrelatable portion of the schema within *path*".

Transition rules are only allowed on _correlatable portions_ of a schema.
A portion of the schema is correlatable if all `array` parent schemas are of type `x-kubernetes-list-type=map`;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2048,12 +2048,10 @@ Unlike other rules, transition rules apply only to operations meeting the follow

<!--
Errors will be generated on CRD writes if a schema node contains a transition rule that can never be
applied, e.g. "*path*: update rule *rule* cannot be set on schema because the schema or its parent
schema is not mergeable".
applied, e.g. "oldSelf cannot be used on the uncorrelatable portion of the schema within *path*".
-->
如果一个模式节点包含一个永远不能应用的转换规则,在 CRD 写入时将会产生错误,例如:
"*path*: update rule *rule* cannot be set on schema because the schema or its parent
schema is not mergeable"。
""oldSelf cannot be used on the uncorrelatable portion of the schema within *path*""。

<!--
Transition rules are only allowed on _correlatable portions_ of a schema.
Expand Down

0 comments on commit 5904467

Please sign in to comment.