简体   繁体   中英

Example of Sidecar Application for Microservices

Spring云配置服务器是否是微服务的补充应用示例?

Do you mean if the Spring Cloud Config Server itself is what the Spring Cloud documentation labels as Sidecar? Then no, as far as I know it is just a plain, regular Spring Boot app.

A Sidecar as referred to in Polyglot support with Sidecar is a Spring Boot application that acts as a bridge between your service infrastructure and a service that is not written in a JVM language. Apps written in Python, Go, Ruby, C#, NodeJS, Erlang or really any other language that can bind something to a port come to mind.

The benefits of the Sidecar are, that your Non-JVM apps

  • service discovery become automatically discoverable through Eureka , which means that JVM services can resolve the host:port/<service-id> of the Non-JVM apps as well as the other way around,
  • monitoring are monitorable through the same health-endpoints-infrastructure that is available in Spring Boot (Actuator), ie by manually providing the health endpoint in the Non-JVM app Eureka knows when the Non-JVM service is down
  • routing/proxying query the services by either manually looking up their hosts/ports or proxying these requests through Zuul , which in turn resolves their current addresses through Eureka
  • balancing be load balanced by Ribbon and
  • configuration may consume configuration properties provided via Spring Cloud Config .

I hope this answer addresses your question, if not (or someone finds it to be inaccurate or misleading) just let me know and I delete it to make room for something more suitable. ;-)

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM