mirror of
https://github.com/etcd-io/etcd.git
synced 2024-09-27 06:25:44 +00:00
Merge pull request #11862 from gyuho/const
etcdserver: compute max request bytes humanized string once
This commit is contained in:
commit
ab494956bf
@ -104,7 +104,8 @@ const (
|
||||
)
|
||||
|
||||
var (
|
||||
storeMemberAttributeRegexp = regexp.MustCompile(path.Join(membership.StoreMembersPrefix, "[[:xdigit:]]{1,16}", "attributes"))
|
||||
recommendedMaxRequestBytesString = humanize.Bytes(uint64(recommendedMaxRequestBytes))
|
||||
storeMemberAttributeRegexp = regexp.MustCompile(path.Join(membership.StoreMembersPrefix, "[[:xdigit:]]{1,16}", "attributes"))
|
||||
)
|
||||
|
||||
func init() {
|
||||
@ -298,7 +299,7 @@ func NewServer(cfg ServerConfig) (srv *EtcdServer, err error) {
|
||||
zap.Uint("max-request-bytes", cfg.MaxRequestBytes),
|
||||
zap.String("max-request-size", humanize.Bytes(uint64(cfg.MaxRequestBytes))),
|
||||
zap.Int("recommended-request-bytes", recommendedMaxRequestBytes),
|
||||
zap.String("recommended-request-size", humanize.Bytes(uint64(recommendedMaxRequestBytes))),
|
||||
zap.String("recommended-request-size", recommendedMaxRequestBytesString),
|
||||
)
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user