This repository has been archived by the owner on Apr 19, 2021. It is now read-only.
Enable auto-kubernetes-client to report API group errors and continu #9
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.
Presently there are conditions that can exist within a Kubernetes cluster that may cause certain API groups to fail to respond to requests for API metadata during the
k8sRequest
to thegroupPath
inside thecreateApi
call.If this should happen, it becomes impossible to communicate with the cluster at all. In our use case, where we our building Kubernetes tooling, we can't perform any communication with the cluster at all even across healthy aspects of the functioning API groups because some unrelated API group might be malfunctioning (example: 'metrics.k8s.io' from 'apis/metrics.k8s.io/v1beta1').
This change would make it so that a console error is reported but then the rest of the available API groups are created so that the available groups can function. It would still be the responsibility of an upstream library to handle errors/rejected promises in the event of missing groups but the alternative is being 100% dead in the water until you have a completely functioning cluster, which doesn't make a lot of sense for operational tooling.
I hope this makes sense. Happy to discuss other approaches, but would love to avoid maintaining a fork. Thank you very much for this library, it's the best way I've seen to interact with the Kubernetes API.