fieldalignment of all structs to save memory

Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
This commit is contained in:
2021-04-27 08:32:47 +03:00
parent ee11f39a2f
commit 86626c5922
78 changed files with 343 additions and 410 deletions

View File

@@ -57,8 +57,8 @@ type Options struct {
RegisterCheck func(context.Context) error
// Codecs map to handle content-type
Codecs map[string]codec.Codec
// Id holds the id of the server
Id string
// ID holds the id of the server
ID string
// Namespace for te server
Namespace string
// Name holds the server name
@@ -104,7 +104,7 @@ func NewOptions(opts ...Option) Options {
Address: DefaultAddress,
Name: DefaultName,
Version: DefaultVersion,
Id: DefaultId,
ID: DefaultID,
Namespace: DefaultNamespace,
}
@@ -143,10 +143,10 @@ func Meter(m meter.Meter) Option {
}
}
// Id unique server id
func Id(id string) Option {
// ID unique server id
func ID(id string) Option {
return func(o *Options) {
o.Id = id
o.ID = id
}
}