Skip to content

Conversation

Diaphteiros
Copy link
Contributor

Release note:

The `Cluster` resource status has now a field `apiServer` that holds the apiserver endpoint for that cluster.


// APIServer is the API server endpoint of the cluster.
// +optional
APIServer string `json:"apiServer,omitempty"`
Copy link
Member

Choose a reason for hiding this comment

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

Since the field is optional, should the string rather be *string?

Suggested change
APIServer string `json:"apiServer,omitempty"`
APIServer *string `json:"apiServer,omitempty"`

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I think the +optional doesn't do anything in this case.
I would prefer to work with string instead of *string, because it is easier (one doesn't have to check for nil pointers all the time).

@Diaphteiros Diaphteiros merged commit e27f451 into main Jun 2, 2025
4 checks passed
@Diaphteiros Diaphteiros deleted the cluster-endpoint branch June 2, 2025 08:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants