升级Spring Cloud Hoxton & Alibaba,认证授权改用Oauth2。
This commit is contained in:
104
README.md
104
README.md
@@ -10,7 +10,7 @@
|
||||
|
||||
## 项目介绍
|
||||
|
||||
`mall-swarm`是一套微服务商城系统,采用了 Spring Cloud Greenwich、Spring Boot 2、MyBatis、Docker、Elasticsearch等核心技术,同时提供了基于Vue的管理后台方便快速搭建系统。`mall-swarm`在电商业务的基础集成了注册中心、配置中心、监控中心、网关等系统功能。 文档齐全,附带全套Spring Cloud教程。
|
||||
`mall-swarm`是一套微服务商城系统,采用了 Spring Cloud Hoxton & Alibaba、Spring Boot 2.3、Oauth2、MyBatis、Docker、Elasticsearch等核心技术,同时提供了基于Vue的管理后台方便快速搭建系统。`mall-swarm`在电商业务的基础集成了注册中心、配置中心、监控中心、网关等系统功能。 文档齐全,附带全套Spring Cloud教程。
|
||||
|
||||
## 系统架构图
|
||||
|
||||
@@ -22,15 +22,14 @@
|
||||
mall
|
||||
├── mall-common -- 工具类及通用代码模块
|
||||
├── mall-mbg -- MyBatisGenerator生成的数据库操作代码模块
|
||||
├── mall-security -- 封装SpringSecurity+JWT的安全认证的模块
|
||||
├── mall-registry -- 基于Eureka的微服务注册中心
|
||||
├── mall-config -- 基于Spring Cloud Config的微服务配置中心
|
||||
├── mall-auth -- 基于Spring Security Oauth2的统一的认证中心
|
||||
├── mall-gateway -- 基于Spring Cloud Gateway的微服务API网关服务
|
||||
├── mall-monitor -- 基于Spring Boot Admin的微服务监控中心
|
||||
├── mall-admin -- 后台管理系统服务
|
||||
├── mall-search -- 基于Elasticsearch的商品搜索系统服务
|
||||
├── mall-portal -- 移动端商城系统服务
|
||||
└── mall-demo -- 微服务远程调用测试服务
|
||||
├── mall-demo -- 微服务远程调用测试服务
|
||||
└── config -- 配置中心存储的配置
|
||||
```
|
||||
|
||||
## 项目文档
|
||||
@@ -47,29 +46,30 @@ mall
|
||||
|
||||
### 后端技术
|
||||
|
||||
| 技术 | 说明 | 官网 |
|
||||
| ---------------- | -------------------- | ---------------------------------------------------- |
|
||||
| Spring Cloud | 微服务框架 | https://spring.io/projects/spring-cloud |
|
||||
| Spring Boot | 容器+MVC框架 | https://spring.io/projects/spring-boot |
|
||||
| Spring Security | 认证和授权框架 | https://spring.io/projects/spring-security |
|
||||
| MyBatis | ORM框架 | http://www.mybatis.org/mybatis-3/zh/index.html |
|
||||
| MyBatisGenerator | 数据层代码生成 | http://www.mybatis.org/generator/index.html |
|
||||
| PageHelper | MyBatis物理分页插件 | http://git.oschina.net/free/Mybatis_PageHelper |
|
||||
| Swagger-UI | 文档生产工具 | https://github.com/swagger-api/swagger-ui |
|
||||
| Elasticsearch | 搜索引擎 | https://github.com/elastic/elasticsearch |
|
||||
| RabbitMq | 消息队列 | https://www.rabbitmq.com/ |
|
||||
| Redis | 分布式缓存 | https://redis.io/ |
|
||||
| MongoDb | NoSql数据库 | https://www.mongodb.com/ |
|
||||
| Docker | 应用容器引擎 | https://www.docker.com/ |
|
||||
| Druid | 数据库连接池 | https://github.com/alibaba/druid |
|
||||
| OSS | 对象存储 | https://github.com/aliyun/aliyun-oss-java-sdk |
|
||||
| MinIO | 对象存储 | https://github.com/minio/minio |
|
||||
| JWT | JWT登录支持 | https://github.com/jwtk/jjwt |
|
||||
| LogStash | 日志收集 | https://github.com/logstash/logstash-logback-encoder |
|
||||
| Lombok | 简化对象封装工具 | https://github.com/rzwitserloot/lombok |
|
||||
| Seata | 全局事务管理框架 | https://github.com/seata/seata |
|
||||
| Portainer | 可视化Docker容器管理 | https://github.com/portainer/portainer |
|
||||
| Jenkins | 自动化部署工具 | https://github.com/jenkinsci/jenkins |
|
||||
| 技术 | 说明 | 官网 |
|
||||
| ---------------------- | -------------------- | ---------------------------------------------------- |
|
||||
| Spring Cloud | 微服务框架 | https://spring.io/projects/spring-cloud |
|
||||
| Spring Cloud Alibaba | 微服务框架 | https://github.com/alibaba/spring-cloud-alibaba |
|
||||
| Spring Boot | 容器+MVC框架 | https://spring.io/projects/spring-boot |
|
||||
| Spring Security Oauth2 | 认证和授权框架 | https://spring.io/projects/spring-security-oauth |
|
||||
| MyBatis | ORM框架 | http://www.mybatis.org/mybatis-3/zh/index.html |
|
||||
| MyBatisGenerator | 数据层代码生成 | http://www.mybatis.org/generator/index.html |
|
||||
| PageHelper | MyBatis物理分页插件 | http://git.oschina.net/free/Mybatis_PageHelper |
|
||||
| Knife4j | 文档生产工具 | https://github.com/xiaoymin/swagger-bootstrap-ui |
|
||||
| Elasticsearch | 搜索引擎 | https://github.com/elastic/elasticsearch |
|
||||
| RabbitMq | 消息队列 | https://www.rabbitmq.com/ |
|
||||
| Redis | 分布式缓存 | https://redis.io/ |
|
||||
| MongoDb | NoSql数据库 | https://www.mongodb.com/ |
|
||||
| Docker | 应用容器引擎 | https://www.docker.com/ |
|
||||
| Druid | 数据库连接池 | https://github.com/alibaba/druid |
|
||||
| OSS | 对象存储 | https://github.com/aliyun/aliyun-oss-java-sdk |
|
||||
| MinIO | 对象存储 | https://github.com/minio/minio |
|
||||
| JWT | JWT登录支持 | https://github.com/jwtk/jjwt |
|
||||
| LogStash | 日志收集 | https://github.com/logstash/logstash-logback-encoder |
|
||||
| Lombok | 简化对象封装工具 | https://github.com/rzwitserloot/lombok |
|
||||
| Seata | 全局事务管理框架 | https://github.com/seata/seata |
|
||||
| Portainer | 可视化Docker容器管理 | https://github.com/portainer/portainer |
|
||||
| Jenkins | 自动化部署工具 | https://github.com/jenkinsci/jenkins |
|
||||
|
||||
### 前端技术
|
||||
|
||||
@@ -87,15 +87,17 @@ mall
|
||||
|
||||
### 开发环境
|
||||
|
||||
工具 | 版本号 | 下载
|
||||
----|----|----
|
||||
JDK | 1.8 | https://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html
|
||||
Mysql | 5.7 | https://www.mysql.com/
|
||||
Redis | 3.2 | https://redis.io/download
|
||||
Elasticsearch | 6.2.2 | https://www.elastic.co/downloads
|
||||
MongoDb | 3.2 | https://www.mongodb.com/download-center
|
||||
RabbitMq | 3.7.14 | http://www.rabbitmq.com/download.html
|
||||
nginx | 1.10 | http://nginx.org/en/download.html
|
||||
| 工具 | 版本号 | 下载 |
|
||||
| ------------- | ------ | ------------------------------------------------------------ |
|
||||
| JDK | 1.8 | https://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html |
|
||||
| Mysql | 5.7 | https://www.mysql.com/ |
|
||||
| Redis | 5.0 | https://redis.io/download |
|
||||
| Elasticsearch | 7.6.2 | https://www.elastic.co/cn/downloads/elasticsearch |
|
||||
| Kibana | 7.6.2 | https://www.elastic.co/cn/downloads/kibana |
|
||||
| Logstash | 7.6.2 | https://www.elastic.co/cn/downloads/logstash |
|
||||
| MongoDb | 4.2.5 | https://www.mongodb.com/download-center |
|
||||
| RabbitMq | 3.7.14 | http://www.rabbitmq.com/download.html |
|
||||
| nginx | 1.10 | http://nginx.org/en/download.html |
|
||||
|
||||
### 搭建步骤
|
||||
|
||||
@@ -106,8 +108,6 @@ nginx | 1.10 | http://nginx.org/en/download.html
|
||||
- `ELK`日志收集系统的搭建请参考:[SpringBoot应用整合ELK实现日志收集](http://www.macrozheng.com/#/technology/mall_tiny_elk);
|
||||
- 使用MinIO存储文件请参考:[前后端分离项目,如何优雅实现文件存储](http://www.macrozheng.com/#/technology/minio_use);
|
||||
- 读写分离解决方案请参考:[你还在代码里做读写分离么,试试这个中间件吧](http://www.macrozheng.com/#/reference/gaea);
|
||||
- 如果想使用`Consul`作为注册及配置中心的话请参考:[Spring Cloud Consul:服务治理与配置中心](http://www.macrozheng.com/#/cloud/consul);
|
||||
- 如果想使用`Nacos`作为注册及配置中心的话请参考:[Spring Cloud Alibaba:Nacos 作为注册中心和配置中心使用](http://www.macrozheng.com/#/cloud/nacos);
|
||||
- `分布式事务`解决方案请参考:[使用Seata彻底解决Spring Cloud中的分布式事务问题!](http://www.macrozheng.com/#/cloud/seata)。
|
||||
|
||||
> Docker环境部署
|
||||
@@ -120,21 +120,31 @@ nginx | 1.10 | http://nginx.org/en/download.html
|
||||
|
||||
## 运行效果展示
|
||||
|
||||
- 注册中心控制台信息:
|
||||
- 查看注册中心注册服务信息,访问地址:http://192.168.3.101:8848/nacos/
|
||||
|
||||

|
||||

|
||||
|
||||
- 监控中心应用信息:
|
||||
- 监控中心应用信息,访问地址:http://192.168.3.101:8101
|
||||
|
||||

|
||||

|
||||
|
||||

|
||||

|
||||
|
||||
- 可视化容器管理:
|
||||

|
||||
|
||||

|
||||
- API文档信息,访问地址:http://192.168.3.101:8201
|
||||
|
||||

|
||||

|
||||
|
||||
- 日志收集系统信息,访问地址:http://192.168.3.101:5601
|
||||
|
||||

|
||||
|
||||
- 可视化容器管理,访问地址:http://192.168.3.101:9000
|
||||
|
||||

|
||||
|
||||

|
||||
|
||||
## 公众号
|
||||
|
||||
|
||||
Reference in New Issue
Block a user