Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Return a default APIClient if we run into an exception #1963

Conversation

ryanjbaxter
Copy link

Fixes #1946

@k8s-ci-robot k8s-ci-robot added the do-not-merge/invalid-commit-message Indicates that a PR should not merge because it has an invalid commit message. label Nov 1, 2021
@k8s-ci-robot
Copy link
Contributor

Thanks for your pull request. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

📝 Please follow instructions at https://git.k8s.io/community/CLA.md#the-contributor-license-agreement to sign the CLA.

It may take a couple minutes for the CLA signature to be fully registered; after that, please reply here with a new comment and we'll verify. Thanks.


Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@k8s-ci-robot k8s-ci-robot added the cncf-cla: no Indicates the PR's author has not signed the CNCF CLA. label Nov 1, 2021
@k8s-ci-robot k8s-ci-robot added the size/S Denotes a PR that changes 10-29 lines, ignoring generated files. label Nov 1, 2021
@ryanjbaxter ryanjbaxter force-pushed the default-apiclient-for-spring-config branch from 4323090 to 471c84e Compare November 1, 2021 19:36
@k8s-ci-robot k8s-ci-robot removed the do-not-merge/invalid-commit-message Indicates that a PR should not merge because it has an invalid commit message. label Nov 1, 2021
@ryanjbaxter
Copy link
Author

/check-cla

@ryanjbaxter
Copy link
Author

I signed it

@ryanjbaxter
Copy link
Author

/check-cla

@k8s-ci-robot k8s-ci-robot added cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. and removed cncf-cla: no Indicates the PR's author has not signed the CNCF CLA. labels Nov 2, 2021
@ryanjbaxter
Copy link
Author

/assign @yue9944882

@@ -25,10 +28,32 @@
@ConditionalOnKubernetesInformerEnabled
public class KubernetesInformerAutoConfiguration {

private static final Log LOG = LogFactory.getLog(KubernetesInformerAutoConfiguration.class);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: conventionally we use slf4j as the logging interface

Copy link
Member

@yue9944882 yue9944882 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

plz run mvn spotless:apply to fix the format error

@ryanjbaxter
Copy link
Author

@yue9944882 @brendandburns sorry for the delay in getting back to this.

I actually think it might be simpler if we just try and create the ApiClient and if that fails we fall back to creating one that points to localhost. Let me know what you think.

@ryanjbaxter ryanjbaxter force-pushed the default-apiclient-for-spring-config branch from 0677a1a to ad0e88a Compare December 17, 2021 14:09
@ryanjbaxter
Copy link
Author

@yue9944882 I believe I fixed the formatting issues, sorry about that

Copy link
Member

@yue9944882 yue9944882 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm
/approve

@ryanjbaxter thanks a bunch!

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Dec 22, 2021
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: ryanjbaxter, yue9944882

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Dec 22, 2021
@k8s-ci-robot k8s-ci-robot merged commit b66a5f6 into kubernetes-client:release-11 Dec 22, 2021
This was referenced Dec 22, 2021
k8s-ci-robot added a commit that referenced this pull request Dec 23, 2021
k8s-ci-robot added a commit that referenced this pull request Jan 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants