-
Notifications
You must be signed in to change notification settings - Fork 3.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
operator: Add zone awareness spec to LokiStack #9315
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some comments
// +kubebuilder:validation:Optional | ||
// +kubebuilder:validation:Minimum:=1 | ||
// +operator-sdk:csv:customresourcedefinitions:type=spec,xDescriptors="urn:alm:descriptor:com.tectonic.ui:number",displayName="Replication Factor" | ||
Factor int32 `json:"factor,omitempty"` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I only discovered this recently but according to [1] if a field is optional and its type doesn't build in nil
then they should be pointers. Now I also know that to not change a project conventions so I'm simply raising the question if this should not be a pointer
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think that for int32, 0 is the nil value, so if the value is 0, it will be omitted, which is the desired result.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Did you leave the index-gateway
and ruler
components intentionally out?
Yes. As per the Enhancement Proposal, this only affects the read and write components. |
But index-gateway is related to the read path |
What this PR does / why we need it:
This PR adds
ReplicationSpec
and deprecatesReplicationFactor
(more details in the enhancement proposal).This new spec will allow adding
TopologySpreadConstraints
to read/write paths' components.Checklist
CONTRIBUTING.md
guide (required)CHANGELOG.md
updateddocs/sources/upgrading/_index.md