Eureka闭源,Spring Cloud就会凉凉吗?

开源
近日,知名服务注册与服务发现工具 Eureka 的 GitHub Wiki 上显示其 2.0 版本的开源工作已经停止。

近日,知名服务注册与服务发现工具 Eureka 的 GitHub Wiki 上显示其 2.0 版本的开源工作已经停止。

笔者朋友圈被 Eureka 2.x 停止开发的新闻刷屏,例如:

  • Eureka 2.0 开源工作宣告停止,继续使用风险自负
  • 凉凉了,Eureka 宣布闭源,Spring Cloud 何去何从?

关于第二篇,我想说,这是在造谣。

不妨来看一下官方的言论,来自 https://github.com/Netflix/eureka/wiki:

The open source work on eureka 2.0 has been discontinued. The code base and artifacts that were released as part of the existing repository of work on the 2.x branch is considered use at your own risk.

看清楚官方的言辞:官方只是说 Eureka 2.0 的开发被停止了,如果您将 Eureka 2.0 分支用在生产,将后果自负!

看起来挺吓人的。但真的那么可怕吗?

关于 Eureka 版本

Eureka 2.x 从来就没有正式发布过! 目前最新的稳定版本是 1.9.3。

笔者第一次看到 Eureka 2.0 的文章是 2016 年,那时候官方宣称要开发 Eureka 2.0,使用小批量的消息推送替代 Eureka 1.x 中的纯心跳机制(基于定时任务)的消息传递。

但是两年过去了,Eureka 2.0 最终没有孵化出来,但是绝不代表 Eureka 的闭源!官方依然在积极地维护 Eureka 1.x!

不妨来看一下 Eureka 的发布历史,来自 https://github.com/Netflix/eureka/releases

从上图中可以看到,Eureka 的版本维护相当勤快!

 Eureka 和服务注册的关系图

谈谈 2.x 的流产

就笔者的研究来看,官方关闭 2.x 分支至少 2 年了。只是最近可能考虑到会有团队会将 Eureka 2.x 用于线上,甚至基于 2.x 开发,所以友情提示一下。

但是问题是:大部分用户都是因为 Spring Cloud 才接触到 Eureka,Spring Cloud 使用的是 Eureka 1.x!退一万步,你会在自己项目中使用一个非正式发布的版本吗?

在我来看,这就是个友情提示,连个新闻都算不上。宣布停止开发已经停止 2 年的分支,还能算是新闻吗?

不是个例

事实上,这不是 Netflix(开源 Eureka 的公司)第一次跳票了。

2016 年,Netflix 宣布将在 2016 年底或 2017 年初开源 Zuul 2.x,结果写完发现太复杂了,而且性能提升也没有达到预期。

于是官方选择完全重构!知道 2018 年 1 月,Zuul 2.x 才被开源,2018 年 4 月才发布到中央仓库!

参考链接:https://github.com/netflix/zuul/tree/1.x

A lot of people are asking about the status of Zuul 2.0. We are actively working on open sourcing it and with it, likely many filters that we use at Netflix. Yes, we realize it’s been a long time coming. When we initially wrote Zuul 2.0, we heavily relied on RxJava to string filters together with Netty. This ended up adding a lot of complexity to the Zuul 2.0 core as well as made it quite difficult to operate and debug. We didn’t think it was right to release Zuul 2.0 like this. So we spent a lot of time refactoring out this pattern, using Netty constructs directly. This took the better part of a year to complete and deploy safely within Netflix. So this work is now done. We are working towards releasing this much better, easier to understand, and more reliable Zuul 2.0. Obviously Netflix’s business priorities take precedence to our open sourcing efforts, so as we get free time we will put efforts to open sourcing! Stay Tuned.

Current Zuul 2 development is on the 2.1 branch

其他项目的类似情况

不妨多聊聊。相信大家都很熟悉 Netty,或者至少听说过。

Netty 也有类似的情况。Netty 团队开源 Netty 5 后,发现代码复杂度过高,同时性能提升也并没有预期中的那么好,于是停止了 Netty 5 的开发。

那是不是说 Netty 5 闭源了?

退一万步

退一万步讲,Eureka 即使闭源,Spring Cloud 也不至于凉凉。Spring Cloud 支持使用 Eureka、Zookeeper、Consul 实现服务发现的能力。

从 Eureka 切换成 Zookeeper 只需要改个依赖,加两行配置就可以了。

总结

总而言之:

  • Eureka 没有闭源,是 Eurkea 2.x 分支不再维护!
  • Spring Cloud 并不强依赖 Eureka,Spring Cloud Commons 实现了通用抽象,允许我们使用自己喜欢的服务发现组件!
  • 悲观是好事,说明有危机感,但是过度解读,消费开发人员的情怀就过分了。

责任编辑:武晓燕 来源: A周立SpringCloud
相关推荐

2017-07-03 08:29:42

Spring Clou服务详解

2017-07-11 14:48:33

Spring Clou服务提供者

2017-08-18 15:14:04

Spring Clou服务消费者

2022-06-09 08:30:59

Istiospring clo

2017-06-25 13:33:25

Spring Clou微服务架构

2023-12-23 18:04:40

服务Eureka工具

2018-12-11 12:52:00

闭源开源协议

2013-11-15 11:06:27

闭源开源

2021-03-08 16:08:21

AIOps工具开源

2021-12-29 10:28:27

鸿蒙HarmonyOS应用

2014-08-22 11:15:52

2012-12-10 14:09:32

Linux开源

2013-11-19 11:55:14

2011-06-08 10:29:37

开源闭源苹果

2010-08-24 09:25:15

Oracle

2017-04-20 13:33:12

代码开源PySonar

2022-10-21 08:17:06

开源项目闭源

2016-12-01 18:52:42

开源闭源

2012-12-11 10:08:48

Linux开源开源代码

2011-06-08 09:15:16

闭源iOS苹果
点赞
收藏

51CTO技术栈公众号