spring-cloud-kubernetes icon indicating copy to clipboard operation
spring-cloud-kubernetes copied to clipboard

It should discover new replicas

Open yleguern opened this issue 1 year ago • 5 comments

Hello

Describe the bug spring-cloud-kubernetes (fabric8) version: 3.1.0 spring-cloud version: 2023.0.0 spring-boot-admin version: 3.2.1 spring-boot version: 3.2.2

I'm using spring-boot-admin with spring-cloud-kubernetes to discover running services and pods on my cluster.
It's working well when I start spring-boot-admin (it discovers all services and pods) but if I had new replicas : nothing changes even after several hours. However if I deploy a new service (even on an another namespace) everything gets discovered.

spring:
    cloud:
        kubernetes:
            client:
                no-proxy: ${KUBERNETES_SERVICE_HOST}
            discovery:
                namespaces:
                    - xxxx
                    - yyyy
                use-endpoint-slices: true
                service-labels:
                    discovery: sba-actuator

yleguern avatar Feb 19 '24 11:02 yleguern

is there a way you can provide a minimal reproducible example? I don't really know how spring-boot-admin works, unfortunately. I also see you use the new feature use-endpoint-slices, can you try without it?

Without an example to reproduce the problem, I don't know how I can help.

wind57 avatar Feb 19 '24 12:02 wind57

Hello @wind57, thanks for your response. I disabled the use-endpoint-slices feature: now it's working like expected. I suppose it's an use-endpoint-slices bug...

yleguern avatar Feb 19 '24 13:02 yleguern

I suppose it's an use-endpoint-slices bug...

could be, it's a recent addition we added. If you guide me through the steps to re-produce this issue, I could try to fix it.

wind57 avatar Feb 19 '24 13:02 wind57

@ryanjbaxter can I ask you please to add the "feedback" label here? Thank you

wind57 avatar Feb 19 '24 15:02 wind57

Seems like the InstanceRegisteredEvent is not being fired https://github.com/spring-cloud/spring-cloud-kubernetes/blob/523971aae9923a9ab14edae398d873ef7ef85b3b/spring-cloud-kubernetes-discovery/src/main/java/org/springframework/cloud/kubernetes/discovery/KubernetesDiscoveryClientAutoConfiguration.java#L81

ryanjbaxter avatar Feb 19 '24 20:02 ryanjbaxter

If you would like us to look at this issue, please provide the requested information. If the information is not provided within the next 7 days this issue will be closed.

spring-cloud-issues avatar Feb 26 '24 20:02 spring-cloud-issues

Closing due to lack of requested feedback. If you would like us to look at this issue, please provide the requested information and we will re-open the issue.

spring-cloud-issues avatar Mar 04 '24 20:03 spring-cloud-issues