gpt4 book ai didi

spring - 如果我已经有Kubernetes(或mesos),为什么需要使用Spring Cloud?

转载 作者:行者123 更新时间:2023-12-02 12:22:47 25 4
gpt4 key购买 nike

我是Spring Cloud的新手,对此有些困惑。 Kubernetes和Spring Cloud都是微服务框架。如果我已经有Kubernetes(或mesos),为什么需要使用Spring Cloud?我注意到许多项目都使用它们。
Kubernetes和Spring Cloud有什么区别?它们都可以提供服务发现,负载平衡等。
我真的很困惑

最佳答案

Kubernetes和Spring Cloud通过微服务解决了很多相同的问题,但是使用了不同的方法和技术。 Redhat写了一篇很棒的文章来解释这一点。这里主要介绍:

Spring Cloud has a rich set of well integrated Java libraries toaddress all runtime concerns as part of the application stack. As aresult, the Microservices themselves have libraries and runtime agentsto do client side service discovery, load balancing, configurationupdate, metrics tracking, etc. Patterns such as singleton clusteredservices, batch jobs are managed in the JVM too.

Kubernetes ispolyglot, doesn’t target only the Java platform, and addresses thedistributed computing challenges in a generic for all languages way.It provides services for configuration management, service discovery,load balancing, tracing, metrics, singletons, scheduled jobs on theplatform level, outside of the application stack. The applicationdoesn’t need any library or agents for client side logic and it can bewritten in any language.

In some areas both platforms rely on similarthird party tools. For example the ELK and EFK stacks, tracinglibraries, etc.

Some libraries such as Hystrix, Spring Boot are usefulequally well on both environments. There are areas where bothplatforms are complementary and can be combined together to create amore powerful solution (KubeFlix and Spring Cloud Kubernetes are suchexamples).

Source: https://developers.redhat.com/blog/2016/12/09/spring-cloud-for-microservices-compared-to-kubernetes/


为了更详细地了解差异和相似性,我建议阅读完整的 article

关于spring - 如果我已经有Kubernetes(或mesos),为什么需要使用Spring Cloud?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/43794098/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com