Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions machine/v1beta1/types_machineset.go
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,14 @@ type MachineSetStatus struct {
// observedGeneration reflects the generation of the most recently observed MachineSet.
// +optional
ObservedGeneration int64 `json:"observedGeneration,omitempty"`
// labelSelector is a label selector, in string format, for Machines corresponding to the MachineSet.
// It is exposed via the scale subresource as status.selector.
// When omitted, the MachineSet controller has not yet reconciled spec.selector into status.labelSelector.
// When present, it may be empty and must not exceed 4096 characters.
// +kubebuilder:validation:MinLength=0
// +kubebuilder:validation:MaxLength=4096
// +optional
LabelSelector string `json:"labelSelector,omitempty"`
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a reasonable upper bounds we can set here?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The labelSelector for MachineSet is typically the machineset name and cluster name. Additionally, user could add their own. There is no limit on how many they can add on the spec. Set this to 4096 as reasonable high number that won't cause issue to existing clusters.

// In the event that there is a terminal problem reconciling the
// replicas, both ErrorReason and ErrorMessage will be set. ErrorReason
// will be populated with a succinct value suitable for machine
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -660,6 +660,15 @@ spec:
labels of the machine template of the MachineSet.
format: int32
type: integer
labelSelector:
description: |-
labelSelector is a label selector, in string format, for Machines corresponding to the MachineSet.
It is exposed via the scale subresource as status.selector.
When omitted, the MachineSet controller has not yet reconciled spec.selector into status.labelSelector.
When present, it may be empty and must not exceed 4096 characters.
maxLength: 4096
minLength: 0
type: string
observedGeneration:
description: observedGeneration reflects the generation of the most
recently observed MachineSet.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -615,6 +615,15 @@ spec:
labels of the machine template of the MachineSet.
format: int32
type: integer
labelSelector:
description: |-
labelSelector is a label selector, in string format, for Machines corresponding to the MachineSet.
It is exposed via the scale subresource as status.selector.
When omitted, the MachineSet controller has not yet reconciled spec.selector into status.labelSelector.
When present, it may be empty and must not exceed 4096 characters.
maxLength: 4096
minLength: 0
type: string
observedGeneration:
description: observedGeneration reflects the generation of the most
recently observed MachineSet.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -660,6 +660,15 @@ spec:
labels of the machine template of the MachineSet.
format: int32
type: integer
labelSelector:
description: |-
labelSelector is a label selector, in string format, for Machines corresponding to the MachineSet.
It is exposed via the scale subresource as status.selector.
When omitted, the MachineSet controller has not yet reconciled spec.selector into status.labelSelector.
When present, it may be empty and must not exceed 4096 characters.
maxLength: 4096
minLength: 0
type: string
observedGeneration:
description: observedGeneration reflects the generation of the most
recently observed MachineSet.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -615,6 +615,15 @@ spec:
labels of the machine template of the MachineSet.
format: int32
type: integer
labelSelector:
description: |-
labelSelector is a label selector, in string format, for Machines corresponding to the MachineSet.
It is exposed via the scale subresource as status.selector.
When omitted, the MachineSet controller has not yet reconciled spec.selector into status.labelSelector.
When present, it may be empty and must not exceed 4096 characters.
maxLength: 4096
minLength: 0
type: string
observedGeneration:
description: observedGeneration reflects the generation of the most
recently observed MachineSet.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -660,6 +660,15 @@ spec:
labels of the machine template of the MachineSet.
format: int32
type: integer
labelSelector:
description: |-
labelSelector is a label selector, in string format, for Machines corresponding to the MachineSet.
It is exposed via the scale subresource as status.selector.
When omitted, the MachineSet controller has not yet reconciled spec.selector into status.labelSelector.
When present, it may be empty and must not exceed 4096 characters.
maxLength: 4096
minLength: 0
type: string
observedGeneration:
description: observedGeneration reflects the generation of the most
recently observed MachineSet.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -617,6 +617,15 @@ spec:
labels of the machine template of the MachineSet.
format: int32
type: integer
labelSelector:
description: |-
labelSelector is a label selector, in string format, for Machines corresponding to the MachineSet.
It is exposed via the scale subresource as status.selector.
When omitted, the MachineSet controller has not yet reconciled spec.selector into status.labelSelector.
When present, it may be empty and must not exceed 4096 characters.
maxLength: 4096
minLength: 0
type: string
observedGeneration:
description: observedGeneration reflects the generation of the most
recently observed MachineSet.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -662,6 +662,15 @@ spec:
labels of the machine template of the MachineSet.
format: int32
type: integer
labelSelector:
description: |-
labelSelector is a label selector, in string format, for Machines corresponding to the MachineSet.
It is exposed via the scale subresource as status.selector.
When omitted, the MachineSet controller has not yet reconciled spec.selector into status.labelSelector.
When present, it may be empty and must not exceed 4096 characters.
maxLength: 4096
minLength: 0
type: string
observedGeneration:
description: observedGeneration reflects the generation of the most
recently observed MachineSet.
Expand Down
1 change: 1 addition & 0 deletions machine/v1beta1/zz_generated.swagger_doc_generated.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 7 additions & 0 deletions openapi/generated_openapi/zz_generated.openapi.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading