envoyproxy / envoyproxy/gateway

Stale Route Parent condition present in Route object

Offen
#774 6 Kommentare 1 Reaktion 0 zugewiesene Personen Auf GitHub ansehen
kind/bug stale
Vorherrschende Sprache
Go
Sterne
3k
Forks
864
Ø Merge
2 T. 2 Std.
Gemergte PRs (30 T.)
140

Beschreibung

*Description*:
When the parent reference in a Route object (on both HTTPRoute and TLSRoute), is updated
to point to a non-existing gateway, the Route parent condition is not updated properly

*Repro steps*:
1. apply `examples/kubernetes/quickstart.yaml` - ensure that Gateway has proper Status conditions, with 1 listener condition
showing `attachedRoutes: 1`. Ensure that the HTTPRoute also has proper Parent Condition present. The httproute parent condition might look something like this
```yaml
status:
parents:
- conditions:
- lastTransitionTime: "2022-12-03T07:23:33Z"
message: Route is accepted
observedGeneration: 1
reason: Accepted
status: "True"
type: Accepted
controllerName: gateway.envoyproxy.io/gatewayclass-controller
parentRef:
group: gateway.networking.k8s.io
kind: Gateway
name: eg
```
2. Now edit the HTTPRoute to point to a non-existing Gateway i.e.
```yaml
parentRefs:
- group: gateway.networking.k8s.io
kind: Gateway
name: eg1
```

*Observation*
While the Gateway status properly specifies the `attachedRoutes: 0`, the HTTPRoute on the other hand shows - what appears to be a stale parent condition. i.e.
```yaml
status:
parents:
- conditions:
- lastTransitionTime: "2022-12-03T07:23:33Z"
message: Route is accepted
observedGeneration: 1
reason: Accepted
status: "True"
type: Accepted
controllerName: gateway.envoyproxy.io/gatewayclass-controller
parentRef:
group: gateway.networking.k8s.io
kind: Gateway
name: eg
```
Which is the same as seen earlier.
Note that the HTTPRoute now has no mention of Gateway `eg` as we changed the reference to `eg1`, but still the Condition shows a condition that was filled earlier, while it was connected to Gateway `eg`.

Beitragsleitfaden

Für dieses Repository ist kein Beitragsleitfaden indexiert

Bewertung

Dieses Issue wurde noch nicht bewertet.

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.