Skip to content

fix(deploy): scope the titiler Service/Deployment selector by release#65

Merged
emmanuelmathot merged 1 commit into
mainfrom
fix/titiler-service-instance-label
Jun 29, 2026
Merged

fix(deploy): scope the titiler Service/Deployment selector by release#65
emmanuelmathot merged 1 commit into
mainfrom
fix/titiler-service-instance-label

Conversation

@emmanuelmathot

Copy link
Copy Markdown
Contributor

Problem

The titiler Deployment selector, pod template labels, and Service selector use only app.kubernetes.io/name + /componentnot the release /instance label. K8s Services route by selector, not name, so although each Service is named <release>-cng-benchmark-titiler, they all share the same selector and therefore match every titiler pod. A runner's display call to its own Service round-robins to an arbitrary release's titiler.

Confirmed live (6 concurrent AOI runs): one release's titiler Service had 6 endpoints, one pod per release.

Harmless when every titiler is identical (same image + sink), but it cross-routes the display metric and breaks per-release isolation.

Fix

Add app.kubernetes.io/instance: {{ .Release.Name }} in three spots in templates/titiler.yaml: the Deployment selector.matchLabels, the pod template labels, and the Service selector. One line each; no behaviour change for a single release.

Test

helm template renders the Service selector with the instance label; after deploy each <release>-...-titiler Service has exactly one endpoint (its own pod).

Follow-on to the 0.6.0 display refactor (#62/#64); surfaced by the CNES SW-France AOI runs.

The titiler Deployment selector, pod template labels, and Service selector
carried only `app.kubernetes.io/name` + `/component`, not the release
`/instance` label. So every titiler Service matched every titiler pod across
all concurrent releases: a runner's display call to its own
`<release>-cng-benchmark-titiler` Service round-robins to ANY release's titiler
pod (confirmed: one Service had 6 endpoints, one per release). Harmless when
every titiler is identical (same image + sink), but it cross-routes display
traffic and breaks per-release isolation. Add the `/instance` label to the
Deployment selector.matchLabels, the pod template labels, and the Service
selector so each Service routes only to its own release's pod.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@emmanuelmathot
emmanuelmathot merged commit e7b4b6d into main Jun 29, 2026
8 checks passed
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.

1 participant