Categorygithub.com/go-micro-saas/nodeid-service

# README

node id service

启动服务;启动请检查配置文件;如果使用配置中心,请跳过执行,先阅读服务配置部分

参考配置文件:config_all.yaml


# 查看帮助
make help

# 运行服务
make run-service
# or
make run-nodeid-service
# or
go run ./app/nodeid-service/cmd/nodeid-service/... -conf=./app/nodeid-service/configs

# 测试服务
make testing-service
# or
make testing-nodeid-service

服务配置

示例如下:

# app 程序
app:
  server_name: nodeid-service
  # 配置方式;值:local、consul、etcd
  config_method: consul

如果app.config_method配置是使用配置中心(consul、etcd、...),首先把配置写入配置中心:

# 执行
make store-configuration
# or
#* `conf`: 启动读取配置
#* `source_dir`: 被存储的配置文件所在文件夹
#* `store_dir`: 存储到配置中心位置
go run ./app/nodeid-service/cmd/store-configuration/... -conf=./app/nodeid-service/configs \
-source_dir=./app/nodeid-service/configs \
-store_dir=go-micro-saas/nodeid-service/develop/v1.0.0

go run ./app/nodeid-service/cmd/store-configuration/... -conf=./app/nodeid-service/configs \
-source_dir=./app/uuid-service/configs \
-store_dir=go-micro-saas/uuid-service/develop/v1.0.0

文档

生成文档:make protoc-api-protobuf

流程图

节点ID颁发流程图

# Packages

No description provided by the author
No description provided by the author