fix(kubernetes): fetch Helm release resources at their real API paths - #5881
Merged
norman-abramovitz merged 1 commit intoSep 3, 2026
Merged
Conversation
The release status poller built each resource URL by hand and got three things wrong. Cluster-scoped kinds (ClusterRole, ClusterRoleBinding, IngressClass) were fetched under the release namespace. The plural was the kind plus "s", so IngressClass became "ingressclasss". And "/status" was appended to every non-core kind, which custom resources such as a Traefik IngressRoute do not have. Each of those answered 404 on every ten-second poll, and a 404 removes the resource from the release, so the preview panel for those nodes opened empty. Resolve plural and scope through the REST mapper Helm's configuration already provides, which is discovery-backed and covers CRDs, and fetch the resource itself since a plain GET carries its status. The name-based guess remains as the fallback when discovery cannot map a kind, now without "/status" and with "es" plurals for s/x/ch/sh endings. Verified on a k3d cluster's traefik release: zero passthrough 404s over the poll window and populated previews for all four previously empty nodes.
norman-abramovitz
approved these changes
Sep 3, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Follow-on from #5880. While that graph was being verified, the backend log
filled with a passthrough 404 every ten seconds for four resources of the
traefik release, and the affected nodes opened an empty preview panel.
getRestURLin the release poller built each URL by hand and got threethings wrong:
the release namespace onto every manifest resource, and the code took a
non-empty namespace to mean "namespaced". ClusterRole, ClusterRoleBinding
and IngressClass all went to
/namespaces/kube-system/....s, with a singleytoiesrule. IngressClass became
ingressclasss; Ingress would beingresss./statuswas appended to every non-core kind unless it was on a shortdeny list. Custom resources such as Traefik's IngressRoute have no status
subresource and 404.
A 404 removes the resource from the release on every poll, which is why the
preview stayed empty and the status never moved.
The fix takes each kind's plural and scope from the REST mapper that Helm's
action.Configurationalready carries. It is discovery-backed, cached, andcovers CRDs. The poller fetches the resource itself, since a plain GET
returns its status, so the
/statussuffix and its deny list are gone.The name-based guess stays as the fallback when discovery cannot map a kind,
now without
/statusand withesplurals fors,x,chandshendings.
NewHelmReleasetakes the mapper in place of aPortalProxyparameter it never used.
TestRestURLcovers namespaced and cluster-scoped kinds through a defaultmapper, the discovery-supplied plural, the unknown-kind fallback, the
no-mapper fallback pluraliser, and
isClusterScoped.Verified on the k3d test cluster's traefik release: zero passthrough 404s
across the poll window, and ClusterRole, ClusterRoleBinding, IngressClass
and IngressRoute all open a populated preview.
make check gategreen.