1 Star 1 Fork 0

xjieinfo / xjgo

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
config.go 943 Bytes
一键复制 编辑 原始数据 按行查看 历史
老马 提交于 2021-06-28 11:55 . XjTime,XjDate增加GobEncode和GobDecode
package xjtypes
//服务的名称等
type App struct {
Name string
Url string
Port int
Rpcport int
}
//如果服务都注册到ETCD,这个可以不要
type Register struct {
Url string
Port int
}
//如果服务间的调用都通过rpc,这个可以不要
type Gateway struct {
Url string
Port int
}
//如果配置使用本地配置文件, 这个可以不要
type Config struct {
Url string
Port int
}
//http和rpc服务的注册管理
type Etcd struct {
Addrs []string
LeaseTime int
}
//jwt验证的密钥和有效时间
type Auth struct {
AccessSecret string
AccessExpire int
}
//数据源
type Datasource struct {
Drivername string
Dsn string
}
//缓存
type Redis struct {
Addr string
Password string
Db int
}
//es搜索
type ElasticSearch struct {
Addr string
Username string
Password string
}
//NSQ消息
type Nsq struct {
Nsqds []string
Nsqlookupds []string
}
1
https://gitee.com/xjieinfo/xjgo.git
git@gitee.com:xjieinfo/xjgo.git
xjieinfo
xjgo
xjgo
v0.8.2

搜索帮助