Giter Site home page Giter Site logo

edisonchou / edc.springcloud.samples Goto Github PK

View Code? Open in Web Editor NEW
191.0 18.0 203.0 112 KB

Spring Cloud作为第二代微服务的代表性框架,已经在国内众多大中小型的公司有实际应用案例。许多公司的业务线全部拥抱Spring Cloud,部分公司选择部分拥抱Spring Cloud。此示例基于Spring Boot 1.5.x编写,展示了Spring Cloud的核心组件的基本使用方式,在学习Spring Cloud时可以参考本示例。

Java 98.17% TSQL 1.83%
spring-boot spring-cloud java eureka

edc.springcloud.samples's Introduction

EDC.SpringCloud.Samples

温馨提示

本示例基于Spring Boot 1.5.x实现,如对Spring Boot不熟悉,可以先学习我的这一篇:《Spring Boot 1.5.x 基础学习示例》。关于微服务基本概念不了解的童鞋,可以先阅读下始祖Martin Fowler的《Microservice》,本文不做介绍和描述。 本示例配套介绍博文请点击这里

Spring Cloud基本介绍

Spring Cloud微服务实战

首先,尽管Spring Cloud带有“Cloud”这个单词,但它并不是云计算解决方案,而是在Spring Boot基础之上构建的,用于快速构建分布式系统的通用模式的工具集。
其次,使用Spring Cloud开发的应用程序非常适合在Docker和PaaS(比如Pivotal Cloud Foundry)上部署,所以又叫做云原生应用(Cloud Native Application)。云原生可以简单地理解为面向云环境的软件架构。
总结,Spring Cloud是一个基于Spring Boot实现的云原生应用开发工具,它为基于JVM的云原生应用开发中涉及的配置管理、服务发现、熔断器、智能路由、微代理、控制总线、分布式会话和集群状态管理等操作提供了一种简单的开发方式

Spring Cloud核心子项目

  • Spring Cloud Netflix:核心组件,可以对多个Netflix OSS开源套件进行整合,包括以下几个组件:
    • Eureka:服务治理组件,包含服务注册与发现
    • Hystrix:容错管理组件,实现了熔断器
    • Ribbon:客户端负载均衡的服务调用组件
    • Feign:基于Ribbon和Hystrix的声明式服务调用组件
    • Zuul:网关组件,提供智能路由、访问过滤等功能
    • Archaius:外部化配置组件
  • Spring Cloud Config:配置管理工具,实现应用配置的外部化存储,支持客户端配置信息刷新、加密/解密配置内容等。
  • Spring Cloud Bus:事件、消息总线,用于传播集群中的状态变化或事件,以及触发后续的处理
  • Spring Cloud Security:基于spring security的安全工具包,为我们的应用程序添加安全控制
  • Spring Cloud Consul : 封装了Consul操作,Consul是一个服务发现与配置工具(与Eureka作用类似),与Docker容器可以无缝集成
  • ......

示例环境版本

  • Java : JDK & JRE 1.8 8u151
  • Spring Boot : 1.5.15.RELEASE
  • Spring Cloud : Edgware.SR3 (PS:Spring Cloud的版本命名是以伦敦地铁站的名字来命名的)

示例简要说明

推荐学习资料

PS:下面资料都是我们项目组新同事以及老同事(.Net技术背景)所采用的学习资料,并不保证适合于所有人。本示例主要也主要是基于下面的资料而写的sample code。
Spring Cloud与Docker微服务架构实战 Spring Cloud微服务实战

周立 Spring Cloud与Docker微服务架构实战:https://book.douban.com/subject/30278673/
程序猿DD SpringCloud基础教程(Dalston版本),Spring Cloud微服务实战:http://blog.didispace.com/Spring-Cloud%E5%9F%BA%E7%A1%80%E6%95%99%E7%A8%8B/
纯洁的微笑 SpringCloud系列教程:http://www.ityouknow.com/spring-cloud

推荐开发环境

Intellij Idea 2018

> Intellij Idea Community 2018版本

阿里巴巴代码规约

> 阿里巴巴代码规约插件

参考博文

Spring Cloud微服务架构基础学习与示例
Java微服务之Spring Boot on Docker(Docker Compose编排Spring Cloud微服务)

edc.springcloud.samples's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

edc.springcloud.samples's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.