mz-debug: read the always-installed v1alpha1 Materialize CRD#37133
Merged
Conversation
PR MaterializeInc#35418 ("Introduce v1 of the Materialize CRD") switched both `mz-debug` imports of the Materialize CR from `v1alpha1::Materialize` to `v1::Materialize`. `kube::Api::<T>` derives its request path from the type's group/version, so these calls began hitting `/apis/materialize.cloud/v1/...`. The `v1` CRD version is only registered when the operator runs with `--install-v1-crd` (helm `operator.args.installV1CRD`, default `false`), and `v1alpha1` remains the storage version that orchestratord still reconciles. On every cluster that has not opted into the new CRD — all of them at release time, since the feature is brand-new and opt-in — there is no `materialize.cloud/v1` endpoint and the API server returns `NotFound`. This silently degrades `mz-debug`: * Auth-mode auto-detection (`get_k8s_auth_mode`) 404s and falls back to `AuthMode::None`, so SQL collection connects with the wrong auth mode on clusters using Password/Sasl/Oidc. * The Materialize CR — usually the single most important object in a support bundle — is dropped from the debug bundle, with only a log warning to indicate why. Revert both imports to `v1alpha1::Materialize`. `v1alpha1` is the stored data, is always registered regardless of `--install-v1-crd`, and carries every field `mz-debug` consumes (`spec.authenticator_kind`). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
alex-hunt-materialize
approved these changes
Jun 18, 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-up to #35418
I assume we want to keep mz-debug working on existing v1alpha CRDs or do we plan to upgrade them all to v1? Otherwise
mz-debugloses:get_k8s_auth_mode) 404s and falls back toAuthMode::None, so SQL collection connects with the wrong auth mode on clusters using Password/Sasl/Oidc.