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

Misleading message is logged during retries if the service not exists #290

Open
gyuuu opened this issue Jan 25, 2019 · 0 comments
Open

Misleading message is logged during retries if the service not exists #290

gyuuu opened this issue Jan 25, 2019 · 0 comments

Comments

@gyuuu
Copy link

gyuuu commented Jan 25, 2019

When the configured service not exists, the logged messages can be misleading.

When service discovery is set up to use a service which not exists, the following message get logged during the retires:
Couldn't connect to the Kubernetes master, [%s] retrying in %s seconds...

Based on the error message, I assumed that the API server is unaccessiable from the pod.

After 10 retries I got the real error message:
Failure executing: GET at: https://kubernetes.default.svc/api/v1/namespaces/test/endpoints/test-service

Configuration:

config.getNetworkConfig().getJoin().getKubernetesConfig().setEnabled(true)
                    .setProperty("namespace", "test")
                    .setProperty("service-name", "test-service");

It's not a big deal at all, however it can lead to a few hour long debug session if your application is killed by the readiness check before the real error message get logged.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant