优化config字段排列,使得内存对齐 (#1521)
* 调整字段顺序,解决config包内存对齐问题 * fix(config):修复内存对齐
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
package config
|
||||
|
||||
type Redis struct {
|
||||
DB int `mapstructure:"db" json:"db" yaml:"db"` // redis的哪个数据库
|
||||
Addr string `mapstructure:"addr" json:"addr" yaml:"addr"` // 服务器地址:端口
|
||||
Password string `mapstructure:"password" json:"password" yaml:"password"` // 密码
|
||||
DB int `mapstructure:"db" json:"db" yaml:"db"` // redis的哪个数据库
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user