Sentinel and Spring Cloud: Building a Better Microservice Ecosystem

Recently, the Spring Cloud community officially merged the spring-cloud-circuitbreaker-sentinel module contributed by Sentinel into Spring Cloud Circuit Breaker. As a result, Sentinel joined the Spring Cloud Circuit Breaker club and became one of Spring Cloud’s official recommendation options. This means that Spring Cloud microservice developers have more options in the area of circuit breaking and Sentinel can be more easily used to ensure the stability of microservices.

1. What Is Spring Cloud Circuit Breaker?

Spring Cloud Circuit Breaker is the official circuit breaker library of Spring Cloud. It provides a centralized set of abstract APIs for circuit breaking, allowing developers to freely choose the appropriate circuit breaker implementation. To date, the officially recommended circuit breakers in this official circuit breaker library include:

  • Hystrix
  • Resilience4J
  • Sentinel
  • Spring Retry

Currently, Spring Cloud Circuit Breaker is in the incubation stage and will soon be merged into the Spring Cloud trunk version for its official release.

Spring Cloud Circuit Breaker:

2. Sentinel Development History

  • 2012

Sentinel was born in the Alibaba Group and its main function is incoming flow control.

  • 2013 to 2018

Sentinel rapidly developed within the Alibaba Group and became a basic technical module that covers all core scenarios. As a result, Sentinel gained experience in a large number of flow control scenarios and developed sophisticated production practices.

  • July 2018

Alibaba announced that the flow control and downgrade framework component Sentinel was officially open source. Prior to this, Sentinel, as the basic module of Alibaba’s “large mid-end and small front-end” architecture, covered all core Alibaba scenarios. Therefore, it had accumulated a lot of experience in traffic consolidation scenarios and developed sophisticated production practices.

  • September 2018

Sentinel V0.2.0 was released with many important features, such as asynchronous call support and hotspot parameter control.

  • October 2018

Sentinel is included in the CNCF Cloud Native Interactive Landscape, which is located in a quadrant of the orchestration and management module.

  • October 2018

Sentinel released its first GA version, V1.3.0, which included improvements to Sentinel console functions, bug fixes, and other product improvements.

  • December 2018

Sentinel V1.4 was released, adding the cluster flow control function that developers desired.

  • March 2019

Sentinel V1.5.0 was released, which introduced Reactive support.

  • April 2019

The Spring Cloud community officially merged the spring-cloud-circuitbreaker-sentinel module contributed by Sentinel into Spring Cloud Circuit Breaker. As a result, Sentinel joined the Spring Cloud Circuit Breaker club and became one of Spring Cloud’s official recommendation options.

  • April 25, 2019

Sentinel V1.6.0 was released, which provided customized support for mainstream API gateways, such as Spring Cloud Gateway and Zuul.

3. Technical features of Sentinel

The core function of Sentinel is to implement flow control, downgrade, and system protection policies for resources based on resource configuration rules. In Sentinel, resource definitions and rule configurations are separate. You must first define resources for the corresponding business logic through the Sentinel API and can then dynamically configure rules as needed.

The advantages and features of Sentinel include:

  • Lightweight: The core library has no extra dependencies and performance loss is small.
  • Convenient access: Sentinel provides an extensive open source ecosystem. Sentinel provides adaptation modules for Dubbo, Spring Cloud, Web Servlet, gRPC, and other common frameworks. You only need to introduce and configure the corresponding dependencies to quickly access them. In addition, Sentinel also provides a minimally-invasive resource annotation method for custom scenarios to facilitate custom access.
  • Wide range of flow control scenarios: Sentinel has supported the core traffic scenarios involved in Alibaba’s Double 11 Shopping Festival over the past 10 years. Its flow control dimensions include flow control indicators, flow control effects (shapes), call relationships, hotspots, and clusters. It also provides adaptive protection mechanisms for the system dimension.
  • Easy-to-use console: The console provides real-time monitoring, machine discovery, and rule management capabilities.
  • Fully scalable design: Sentinel provides diverse SPIs, allowing you to add custom logic as needed.

4. Who Is Using Sentinel?

Currently, many enterprise users are using Sentinel’s open source and cloud versions, including SF, Vivo, MissFresh, Pinduoduo, EQXIU, iQiyi, Rongjinsuo, VIPKID, Himalayan FM, and Bairong Financial Services (in order of registration). We also launched the “Who is using Sentinel” issue in the community. You can go to this page to learn about the application scenarios of various enterprises.

At the same time, we provided Sentinel cloud implementation and integrated architecture visualization, fault drills, and other functions to form the Alibaba Cloud High Availability Service (AHAS). Our goal is to help more developers more easily access application high availability capabilities.

5. Future Prospects of Sentinel

In the future, Sentinel will continue to explore rule-free capacity protection, provide more adaptive flow control policies, and better implement flow control while taking system capacity into account. In addition, Sentinel will support a wider open source ecosystem, including API Gateway, Service Mesh, and multilingual clients. It will abstract standard indicators and monitoring interfaces to facilitate integration with common monitoring systems, such as Prometheus. Going forward, Sentinel will further strengthen its cluster flow control capability, enhance support for the Cloud Native ecosystem and Service Mesh, and play a greater role in improving stability assurance in Cloud Native fields.

Open Source Projects Related to Sentinel

Sentinel Contributors

@sczyh30, @carpenterLee, @cdfive, @jasonjoo2010, @mjaow, @canglang1973, @talshalti, @kexianjun, @yikangfeng, @luoxn28, @all4you, @nicktan, @jz0630, @bitonly, @zhaixiaoxiang, @dqing0, @paulkennethkent, @shxz130, @zhousiliang163, @beston123, @lawrencewu, @blindpirate, @HaojunRen, @ATAXGT, @hantianwei, @MickMo, @yklove, @xburning, @yanlinly, @aalmiray, @Leishunyu, @wangjunwei87, @kangyl, @Arlmls, @YoungHu, @foreveryang321, @fangjian0423, @allencloud, @ro9er, @xcaspar, @shannon312, @waveng, @yfh0918, @refactormachine, @jialianglinjl, @kimmking, @nobodyiam, @guonanjun, @manzhizhen, @xg1907


Follow me to keep abreast with the latest technology news, industry insights, and developer trends.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store