AlinsRan commented on code in PR #2856:
URL:
https://github.com/apache/apisix-ingress-controller/pull/2856#discussion_r3947161008
##########
api/v1alpha1/gatewayproxy_types.go:
##########
@@ -178,6 +179,19 @@ type GatewayProxy struct {
// GatewayProxySpec defines configuration of gateway proxy instances,
// including networking settings, global plugins, and plugin metadata.
Spec GatewayProxySpec `json:"spec,omitempty"`
+
+ // Status defines the current state of Gateway Proxy.
+ //
+ // +kubebuilder:default={conditions: {{type: "DataPlaneAvailable",
status: "Unknown", reason:"Pending", message:"Waiting for controller",
lastTransitionTime: "1970-01-01T00:00:00Z"}}}
Review Comment:
This default is never overwritten on the happy path — an always-healthy
GatewayProxy reports `Waiting for controller` forever. That contradicts the
"good" example in the PR description, where `status: "True"` is shown as the
healthy steady state.
Cause: `handleStatusUpdate` writes the success condition only for keys that
were in the *previous* failure set, and nothing else ever writes
`DataPlaneAvailable`. Two effects:
- healthy from the start never turns `True`
- a stale `False` survives a restart — `d.statusUpdateMap` is in-memory, so
the success branch never fires after a restart
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]