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

Eureka Client Health Check Handler not sending correct status back to Eureka server #30066

Closed
kamaldesingh opened this issue Mar 4, 2022 · 3 comments
Labels
for: external-project For an external project and not something we can fix status: invalid An issue that we don't feel is valid

Comments

@kamaldesingh
Copy link

Hello Team,

I have upgraded my application and below are details for same.

Previous Version-
spring boot-1.5.6.RELEASE
spring cloud version-Edgware.M1

Migrated Version-
spring boot-2.4.4
spring cloud version-2020.0.2

Herein, after migration I am faced issue with Client Eureka Health Check handler sending status as up always even though one of dependency say DB is down. This happens only in case where we have 2 or more beans of same type supposing in my application I had 2 LDAP connections and out of which one was down. Ideally, Eureka Client Health Check Handler should have sent DOWN status to Eureka Server but when I debugged it was sending UP status. Moreover, same works fine if I only have 1 LDAP connection then if connection is DOWN it sends back correct status.

Moreover, if we hit actuator health endpoint then it shows correct status as down but Eureka Client Health Check Handler sends UP status back to Eureka Server. Additionally, we have enabled the eureka health check by specifying property in application properties - eureka.client.healthcheck.enabled=true.

It was working fine in previous version we were using even I observed this is working fine with Spring Boot-2.1.18.RELEASE version, post that issue is occurring.

One more observation is that in Spring Boot 2.4.4 we saw that if we have 2 beans of same type they are getting registered under HealthContributor bean whereas in versions till Spring Boot-2.1.18.RELEASE beans were registered under HealthIndicators bean.

I am attaching the jsons from Spring Boot -1.5.6.RELEASE, 2.4.4 version with one bean and multiple beans of same type. Here you would see that for LDAP if I say we have nested components the health status by Eureka client for same is being skipped and if we don't have nested components in LDAP bean or any other dependency then health check by Eureka client is being checked for them as well.

Spring_Boot-2 4 4_Single_Bean_Working_Fine_Issue

Spring_Boot-1 5 6 RELEASE_Working_Fine

Spring_Boot-1 5 6 RELEASE_Nested_Component_Issue

@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged label Mar 4, 2022
@wilkinsona
Copy link
Member

Thanks for the report. Unfortunately, I'm not sure that I understand the problem that you're facing. You've mentioned Eureka several times, but Spring Boot has no Eureka support. I think that you've said that the Actuator's health endpoint is returned the correct status but the Eureka Client Health Check Handler is not. If so, that sounds like something that it out of Spring Boot's control and the problem should be raised with the maintainer of the health check handler.

If you believe you've found a bug and you'd like us to investigate, please provide a complete yet minimal sample that reproduces the problem you've described. Also, please note that OSS support for Spring Boot 2.4.x ended in November 2021 so any fix will only be made in 2.5.x at the earliest. The sample you provide should also use Spring Boot 2.5 or 2.6.

@wilkinsona wilkinsona added the status: waiting-for-feedback We need additional information before we can continue label Mar 4, 2022
@kamaldesingh
Copy link
Author

Thanks for the report. Unfortunately, I'm not sure that I understand the problem that you're facing. You've mentioned Eureka several times, but Spring Boot has no Eureka support. I think that you've said that the Actuator's health endpoint is returned the correct status but the Eureka Client Health Check Handler is not. If so, that sounds like something that it out of Spring Boot's control and the problem should be raised with the maintainer of the health check handler.

If you believe you've found a bug and you'd like us to investigate, please provide a complete yet minimal sample that reproduces the problem you've described. Also, please note that OSS support for Spring Boot 2.4.x ended in November 2021 so any fix will only be made in 2.5.x at the earliest. The sample you provide should also use Spring Boot 2.5 or 2.6.

Hello Andy,

Yes, I am referring to EurekaHealthCheckHandler present under spring-cloud-netflix-eureka-client jar. I am referring to health status being returned from this class back to Spring Cloud Netflix Eureka Server.

@spring-projects-issues spring-projects-issues added status: feedback-provided Feedback has been provided and removed status: waiting-for-feedback We need additional information before we can continue labels Mar 4, 2022
@wilkinsona
Copy link
Member

Thanks for the clarification. Spring Cloud Netflix is managed as a separate project. Please raise any problems related to EurekaHealthCheckHandler with that project.

@wilkinsona wilkinsona added status: invalid An issue that we don't feel is valid for: external-project For an external project and not something we can fix and removed status: waiting-for-triage An issue we've not yet triaged status: feedback-provided Feedback has been provided labels Mar 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
for: external-project For an external project and not something we can fix status: invalid An issue that we don't feel is valid
Projects
None yet
Development

No branches or pull requests

3 participants