Skip to content

Commit 347f50a

Browse files
committed
doc: update README.md
1 parent a8f008c commit 347f50a

File tree

2 files changed

+9
-13
lines changed

2 files changed

+9
-13
lines changed

README.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ Microservice framework implemented based on Golang.
2424
## Framework
2525
```shell
2626
├─api 存放与外部交互的接口及 proto 文件
27-
│ ├─metadata
27+
│ ├─metadata 引用 kratos 发现所有 gRPC 服务接口
2828
│ └─user
2929
│ └─v1
3030
├─app 具体服务相关的实现
@@ -52,15 +52,15 @@ Microservice framework implemented based on Golang.
5252
│ ├─app.go user 服务生成逻辑
5353
│ └─rpc.go user 模块的 rpc 服务 初始化逻辑
5454
├─cmd 服务启动入口
55-
│ ├─admin
55+
│ ├─admin 启动示例 admin 服务
5656
│ └─user 启动示例 user 服务
5757
├─configs 配置文件
5858
│ ├─admin
5959
│ └─user
6060
├─gmicro 微服务相关包
6161
│ ├─app 服务启动相关的结构体
6262
│ │ └─app.go 这个 app 是 GRPC,服务名称,注册中心等的集合
63-
│ ├─code
63+
│ ├─code 有一些公用的错误码
6464
│ ├─core 底层共通核心的包
6565
│ │ ├─metric
6666
│ │ └─trace 链路追踪,采用 opentemlemetry
@@ -69,7 +69,7 @@ Microservice framework implemented based on Golang.
6969
│ └─server
7070
│ ├─restserver http 服务的初始化配置
7171
│ │ ├─middlewares http 服务的中间件
72-
│ │ │ ├─auth
72+
│ │ │ ├─auth 认证相关中间件,包括 jwt,cache,basic
7373
│ │ │ └─tracing.go 只是向gin中封装了 jeager 的 span 的相关信息,待上报的时候,才能入库
7474
│ │ ├─pprof http 服务的 pprof 相关逻辑
7575
│ │ └─validation http 服务的参数校验
@@ -100,9 +100,9 @@ Microservice framework implemented based on Golang.
100100
│ │ └─help.go 帮助信息
101101
│ ├─common 共通相关的包
102102
│ │ ├─auth
103-
│ │ ├─cli
103+
│ │ ├─cli 命令行工具相关的包
104104
│ │ │ ├─flag
105-
│ │ │ └─globalflag
105+
│ │ │ └─globalflag 全局命令行工具
106106
│ │ ├─core
107107
│ │ ├─json
108108
│ │ ├─meta
@@ -130,7 +130,7 @@ Microservice framework implemented based on Golang.
130130
│ │ │ └─wait
131131
│ │ ├─validation
132132
│ │ │ └─field
133-
│ │ └─version
133+
│ │ └─version 服务的版本号
134134
│ │ └─verflag
135135
│ ├─errors 基础的 error 包 可以单独使用
136136
│ ├─host

gmicro/app/app.go

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -9,15 +9,11 @@ import (
99
"syscall"
1010
"time"
1111

12-
"golang.org/x/sync/errgroup"
13-
12+
"github.com/CoderI421/gframework/gmicro/registry"
1413
"github.com/CoderI421/gframework/gmicro/server"
15-
1614
"github.com/CoderI421/gframework/pkg/log"
17-
1815
"github.com/google/uuid"
19-
20-
"github.com/CoderI421/gframework/gmicro/registry"
16+
"golang.org/x/sync/errgroup"
2117
)
2218

2319
type App struct {

0 commit comments

Comments
 (0)