diff --git a/extensions/kubernetes-config/runtime/src/main/java/io/quarkus/kubernetes/config/runtime/KubernetesConfigSourceFactory.java b/extensions/kubernetes-config/runtime/src/main/java/io/quarkus/kubernetes/config/runtime/KubernetesConfigSourceFactory.java index 7dfc1b79a389e..f3a98ccec4ea5 100644 --- a/extensions/kubernetes-config/runtime/src/main/java/io/quarkus/kubernetes/config/runtime/KubernetesConfigSourceFactory.java +++ b/extensions/kubernetes-config/runtime/src/main/java/io/quarkus/kubernetes/config/runtime/KubernetesConfigSourceFactory.java @@ -11,7 +11,6 @@ import io.fabric8.kubernetes.api.model.ConfigMap; import io.fabric8.kubernetes.api.model.Secret; import io.fabric8.kubernetes.client.KubernetesClient; -import io.quarkus.runtime.configuration.AbstractRawDefaultConfigSource; import io.smallrye.config.ConfigSourceContext; import io.smallrye.config.ConfigSourceContext.ConfigSourceContextConfigSource; import io.smallrye.config.ConfigSourceFactory; @@ -51,6 +50,7 @@ public Iterable getConfigSources(final ConfigSourceContext context .getConfigMapping(KubernetesConfigBuildTimeConfig.class); KubernetesConfigSourceConfig kubernetesConfigSourceConfig = config.getConfigMapping(KubernetesConfigSourceConfig.class); + // TODO - radcortez - Move the check that uses the build time config to the processor and skip the builder registration if ((!kubernetesConfigSourceConfig.enabled() && !kubernetesConfigBuildTimeConfig.secretsEnabled()) || isExplicitlyDisabled(context)) { log.debug( @@ -84,7 +84,7 @@ Iterable getConfigSources(final KubernetesConfigSourceConfig confi private boolean isExplicitlyDisabled(ConfigSourceContext context) { ConfigValue configValue = context.getValue("quarkus.kubernetes-config.enabled"); - if (AbstractRawDefaultConfigSource.NAME.equals(configValue.getConfigSourceName())) { + if ("DefaultValuesConfigSource".equals(configValue.getConfigSourceName())) { return false; } if (configValue.getValue() != null) {