Skip to content

Commit

Permalink
fix(MeshHTTPRoute): weight should be a minimum of 0 (#5653)
Browse files Browse the repository at this point in the history
Signed-off-by: Mike Beaumont <mjboamail@gmail.com>
  • Loading branch information
michaelbeaumont authored Jan 11, 2023
1 parent 429fa77 commit 25f2275
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -58,5 +58,6 @@ type Filter struct {

type BackendRef struct {
common_api.TargetRef `json:",omitempty"`
Weight int `json:"weight,omitempty"`
// +kubebuilder:validation:Minimum=0
Weight uint `json:"weight,omitempty"`
}
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ properties:
description: Tags used to select a subset of proxies by tags. Can only be used with kinds `MeshSubset` and `MeshServiceSubset`
type: object
weight:
minimum: 0
type: integer
type: object
type: array
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,7 @@ spec:
`MeshSubset` and `MeshServiceSubset`
type: object
weight:
minimum: 0
type: integer
type: object
type: array
Expand Down

0 comments on commit 25f2275

Please sign in to comment.