# spring-cloud-alibaba **Repository Path**: lizhou828/spring-cloud-alibaba ## Basic Information - **Project Name**: spring-cloud-alibaba - **Description**: No description available - **Primary Language**: Java - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2021-12-09 - **Last Updated**: 2022-08-13 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # spring-cloud-alibaba ## 本项目演示操作步骤: ### 1、准备工作 * 启动nacos服务端(单例方式、默认8848端口): D:\ProgramFiles\springCloudAlibaba\nacos\bin>startup.cmd -m standalone 访问地址:http://localhost:8848/naco, 默认账号密码都是:nacos * 在nacos 新增相关的命名空间、DataID、相关配置, 详情见各个应用的 bootstrap.yaml、bootstrap.properties等配置文件 * 启动sentinel界面(默认8080端口): D:\ProgramFiles\springCloudAlibaba>java -jar sentinel-dashboard-1.8.2.jar 访问地址:http://localhost:8080/#/login , 默认账号密码都是:sentinel * 启动 provider-demo-9001、 provider-demo-9002 等提供者(均已配置nacos服务端地址) * 再启动消费者 consumer-demo-9000 ### 2、基本调用演示 健康检查接口: http://localhost:9000/liveness http://localhost:9001/liveness http://localhost:9002/liveness 调用入口 http://localhost:9000/sentinelDemo ### 2、sentinel调用演示 访问 http://localhost:8080/#/dashboard/flow/consumer-demo ,,对http://localhost:9000/sentinelDemo 这个URL新增流控规则, 然后 不停的访问 http://localhost:9000/sentinelDemo 以验证流控规则是否生效 #### 软件架构说明 Nacos 用于配置中心、服务注册、服务发现 Sentinel 用于服务容错,具体体现于:流量控制(限流)、服务熔断、服务降级 Seata 用于分布式事务 RocketMQ 用于消息驱动 Sleuth 用于链路追踪 Gateway 用户网关服务 #### nacos 在windows下的使用教程 1. 源码地址: https://github.com/alibaba/nacos 2. 快速入门地址:https://nacos.io/zh-cn/docs/quick-start.html 3. 环境要求:JDK8+ , Maven3.2+ 4. 下载安装包: https://github.com/alibaba/nacos/releases/download/2.0.3/nacos-server-2.0.3.zip 5. 解压到 D:\ProgramFiles\springCloudAlibaba\nacos_2_0_3 目录 6. 单机启动 D:\ProgramFiles\springCloudAlibaba\nacos_2_0_3\bin>startup.cmd -m standalone 7. 访问管理页面 http://localhost:8848/nacos/index.html, 账号密码都是: nacos #### sentinel在windows下的使用教程 1. 源码地址:https://github.com/alibaba/Sentinel/releases 2. 下载sentinel包:https://github.com/alibaba/Sentinel/releases/download/1.8.2/sentinel-dashboard-1.8.2.jar 3. 放到 D:\ProgramFiles\springCloudAlibaba 目录下 4. 启动 D:\ProgramFiles\springCloudAlibaba>java -jar sentinel-dashboard-1.8.2.jar,默认808端口 与Tomcat默认的端口冲突,如果需要修改Sentinel默认启动端口,使用参数:-Dserver.port=8070 5. 访问管理页面:http://localhost:port/ , 账号密码都是:sentinel 6. xxxx #### 参与贡献 1. Fork 本仓库 2. 新建 Feat_xxx 分支 3. 提交代码 4. 新建 Pull Request #### 参考文档 [spring-cloud-alibaba版本及其对应版本说明](https://github.com/alibaba/spring-cloud-alibaba/wiki/%E7%89%88%E6%9C%AC%E8%AF%B4%E6%98%8E)