Should I use conul for service discovering on kubernetes?

I use spring cloud for microservice develpment,and I will deploy my application on kubernetes. I found spring cloud had provided Spring Cloud Kubernetes for service discovering , so if I just need consul for service discovering,shoud I use Spring Cloud Kubernetes or Spring Cloud Consul ?

Hi @FunnyYish,

I have not used either of those libraries on Kubernetes, but I thought I’ll leave my thoughts from the Consul on Kubernetes perspective.

The short answer is that you should probably use the Consul specific Spring Cloud library. The long answer is it depends on how you’re deploying Consul on Kubernetes itself.

If I understand correctly, Spring Cloud Kubernetes is for native Kubernetes services. The official Consul Helm chart comes with a feature called Catalog Sync, which allows you to sync your Consul services to Kubernetes as native Kubernetes services, and vice versa. If you sync all your Consul services, then, in theory, you could use Spring Cloud Kubernetes too.

Hope this helps!