Cloud-platform is the first micro-service development Platform based on Spring Cloud in China. It has a unified authorization and authentication background management system, including multiple modules such as user management, resource rights management and gateway API management. It supports the parallel development of multi-service systems and can serve as the development scaffolding for back-end services. Simple code, clear architecture, suitable for learning and direct project use. The core technology adopts Spring Boot 2.1.2 and Spring Cloud (Greenwich.RELEASE) related core components, Nacos registration and configuration center, integrated flow guard Sentinel, and vue-element-Admin component at the front end. Elastic Search integrates itself.

Code cloud open-source address:

https://gitee.com/geek_qi/cloud-platform
Copy the code

Github

https://github.com/wxiaoqi/Spring-Cloud-Platform
Copy the code

The module specification

 

Architecture in this paper,

Zhongtai chemical front end

Integrated D2admin China front-end, optimized the front-end architecture and function layout, and supported China Service application development.

JWT authentication

User authentication and information transfer are carried out through JWT to ensure stateless transfer of users between services.

monitoring

Spring Boot Admin is used to monitor the running status of each independent Service. Use the Hystrix Dashboard to view the running status and call frequency of the interface in real time.

Load balancing

In addition to node.js and Nginx, Spring Cloud series Zuul and Ribbon can help us carry out normal gateway control and load balancing. Among them, the extension and reference of foreign projects is based on the Zuul current limiting plug-in of JWT.

Service registration and invocation

Nacos-based service registration and invocation. Using Feign in Spring Cloud, we can achieve the same coding experience when requesting a remote service using HTTP as when calling a local method. The developer does not know that it is a remote method, let alone an HTTP request.

Fusing and flow control

Integrates Ali Sentinel for interface flow control and avoids “avalanche” of calls between services through fusing and downgrading processing.


Screenshot function

The basic function

Screenshot function