Skip to content

Commit 3f5b00a

Browse files
committed
fix(perses): drop ready-state propagation, add explanatory note
kro v0.9.2 strips includeWhen-gated resources from the CEL context at compile time, making it impossible to propagate their readiness into status expressions. All workarounds tried (sentinel ConfigMap, ternary expressions) either fail compilation or produce unreliable results. status.ready is set to the static literal true in the Perses RGD. A comment marks where real propagation would live and links to the upstream issue. obs-stack.status.perses.ready is kept (removing it would be a breaking CRD change) but is excluded from the ready gate. See: kubernetes-sigs/kro#926 (comment) Signed-off-by: Michael Sprauer <Michael.Sprauer@sap.com>
1 parent 982b25d commit 3f5b00a

2 files changed

Lines changed: 7 additions & 6 deletions

File tree

resource-graph-definitions/observability-stack.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,9 @@ spec:
9595
ready: ${openTelemetryOperator.status.ready}
9696
openTelemetryCollector:
9797
ready: ${openTelemetryCollector.status.ready}
98+
# NOTE: perses.ready is always true — kro v0.9.2 cannot propagate readiness
99+
# from includeWhen-gated resources into status expressions.
100+
# See: https://github.com/kubernetes-sigs/kro/issues/926#issuecomment-4313907502
98101
perses:
99102
ready: ${perses.status.ready}
100103
prometheusOperator:

resource-graph-definitions/perses.yaml

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -40,13 +40,11 @@ spec:
4040
limits:
4141
memory: string | default="512Mi"
4242
cpu: string | default="500m"
43+
# NOTE: status.ready propagation is not implemented here.
44+
# kro v0.9.2 removes includeWhen-gated resources from the CEL context at
45+
# compile time, making it impossible to reference their status in expressions.
46+
# See: https://github.com/kubernetes-sigs/kro/issues/926#issuecomment-4313907502
4347
status:
44-
# kro v0.9.2 does not allow status expressions to reference resources gated
45-
# by includeWhen (they are removed from the CEL context at compile time).
46-
# Instance readiness is correctly gated by persesKustomization.readyWhen
47-
# when enabled, and is vacuously true when disabled (excluded resources
48-
# do not block instance readiness). status.ready is therefore always true.
49-
# See: https://github.com/kubernetes-sigs/kro/issues/926#issuecomment-4313907502
5048
ready: true
5149
lastAttemptedRevisionDigest: ""
5250

0 commit comments

Comments
 (0)