Learning SpringCloud (1) Introduction

spring cloud Introduction

Spring Cloud is an ordered collection of a series of frames. It uses facilitate the development of Spring Boot cleverly simplify the development of distributed systems infrastructure, such as service discovery registration, distribution center, message bus, load balancing, circuit breakers, monitoring and other data, can be done with a style of development of Spring Boot and a key to start the deployment. Spring Cloud did not reinventing the wheel, it just will present each company developed more mature, and can withstand the test of actual service framework combined, re-packaged masked a complex configuration and implementation of the principles by Spring Boot style and, ultimately, developers set aside a simple and easy to understand, easy to deploy and easy maintenance of distributed systems development kit.

Spring Cloud Composition

Spring Cloud sub-projects may be roughly classified into two types, one is the framework of the existing mature "Spring Boot" of encapsulation and abstraction, but also the largest number of items; the second is the development infrastructure part of a distributed system implementation, such as Spring Cloud Stream is played kafka, such a role ActiveMQ. We want a quick practice for micro-services developers, the first class sub is sufficient to use, such as:

  • Spring Cloud Netflix package is a set of distributed services framework for Netflix development, including discovery and registration services, load balancing, circuit breakers, REST client, request routing.
  • Spring Cloud Config configuration information center preservation, Spring Cloud Bus configuration can be achieved dynamically modify the configuration file
  • Spring Cloud Bus distributed message queue, is the encapsulation of Kafka, MQ of
  • Spring Cloud Security Spring Security of the package, and can be used with Netflix
  • Spring Cloud Zookeeper Zookeeper for packaging, so that it can be configured in other sub-use Spring Cloud
  • Spring Cloud Eureka Spring Cloud Eureka is part of the Spring Cloud Netflix Micro suite of services, which is based Netflix Eureka made a second package, is responsible for completion of the service management function micro-service architecture.

Spring Cloud advantages and disadvantages

Its main advantages are:

  • Synthesizer, Spring Cloud includes all aspects of micro-services architecture.
  • Convention over configuration, based on the comments, no configuration file.
  • Lightweight components, Spring Cloud integration of components is mostly lightweight, and are experts in their field.
  • Development of simple, Spring Cloud a large number of various components of the package, thus simplifying development.
  • The development of flexible, Spring Cloud components are decoupled, developers have the flexibility to select the components needed.

Next, we look at its shortcomings:

  • Complex project structure, each component or each service need to create a project.
  • High threshold deployment, the deployment of the project need to meet Docker containers such as technology cluster deployment, but in order to understand Docker, high learning costs.

Chart

  • Spring Cloud Config: Configuration management development kit that lets you put configuration into a remote server, now supports local storage, Git and Subversion.

  • Spring Cloud Bus: event message bus for the cluster (e.g., configuration change event) and the propagation state change, may be implemented jointly with Spring Cloud Config hot deploy

  • Spring Cloud Netflix: Netflix components for a variety of development tools provided by the package, including Eureka, Hystrix, Zuul, Archaius and so on.

  • Netflix Eureka: Cloud load balancing, a REST-based services, for location services, for failover Drive load balancing servers and the intermediate layer.

  • Netflix Hystrix: fault-tolerant management tool that aims to control node services and third-party libraries, providing a more robust fault tolerance for delay and failure.

  • Netflix Zuul: Edge service tools, providing dynamic routing, monitoring, edge flexibility, security and other services.

  • Netflix Archaius: Configuration Management API, contains a series of configuration management API, providing a dynamic type of property, thread-safe configuration operations, polling frame, a callback mechanism and other functions.

  • Spring Cloud for Cloud Foundry: binding agreement to service by Oauth2 CloudFoundry, CloudFoundry is VMware launched an open source PaaS cloud platform.

  • Spring Cloud Sleuth: log collection kit, a package Dapper, Zipkin and HTrace operation.

  • Spring Cloud Data Flow: large data operation tool, the operation data stream through the command line.

  • Spring Cloud Security: Security Toolkit to add security controls for your application, mainly refers to OAuth2.

  • Spring Cloud Consul: Consul encapsulates operation, Consul is a service discovery and configuration tools, it can be seamlessly integrated with Docker containers.

  • Spring Cloud Zookeeper: Zookeeper operations toolkit for using the service registration and discovery zookeeper way.

  • Spring Cloud Stream: dataflow operations development kit, a package of message transmission and Redis, Rabbit, Kafka like.

  • Spring Cloud CLI: Based on Spring Boot CLI, allows you to quickly create command line cloud components.

Spring Cloud prospects

Spring Cloud Internet for small and medium sized companies, is a blessing, because these companies often do not have the strength or there is not enough funding to develop their own distributed systems infrastructure, using Spring Cloud-stop solutions in business calmly while the development of greatly reducing development costs. Meanwhile, in recent years, with the popular micro-service architecture and concepts Docker containers, it makes Spring Cloud in the future more and more "cloud" of software development style of a neutral place, especially in a wide variety of solutions are currently distributed in It offers a standardized, full-stop technical solution, meaning Servlet specification may be comparable to the birth of the year, effectively promote the progress of the technical level of the server software system.

Guess you like

Origin blog.csdn.net/weixin_33755847/article/details/91368394