Skip to content
Snippets Groups Projects
Commit 7dfb595a authored by ko_oler's avatar ko_oler
Browse files

добавлены ключи для mapstructure

parent dec664a5
No related branches found
No related tags found
No related merge requests found
...@@ -26,17 +26,17 @@ func (l Level) String() string { ...@@ -26,17 +26,17 @@ func (l Level) String() string {
} }
type Entry struct { type Entry struct {
ID string `json:"id" bson:"id"` ID string `json:"id" bson:"id" mapstructure:"id"`
Timestamp time.Time `json:"timestamp,omitempty" bson:"timestamp,omitempty"` Timestamp time.Time `json:"timestamp,omitempty" bson:"timestamp,omitempty" mapstructure:"timestamp"`
LogLevel Level `json:"log_level,omitempty" bson:"log_level,omitempty"` LogLevel Level `json:"log_level,omitempty" bson:"log_level,omitempty" mapstructure:"log_level"`
Message string `json:"message,omitempty" bson:"message,omitempty"` Message string `json:"message,omitempty" bson:"message,omitempty" mapstructure:"message"`
Category string `json:"category,omitempty" bson:"category,omitempty"` Category string `json:"category,omitempty" bson:"category,omitempty" mapstructure:"category"`
Component string `json:"component,omitempty" bson:"component,omitempty"` Component string `json:"component,omitempty" bson:"component,omitempty" mapstructure:"component"`
Event string `json:"event,omitempty" bson:"event,omitempty"` Event string `json:"event,omitempty" bson:"event,omitempty" mapstructure:"event"`
Object string `json:"object,omitempty" bson:"object,omitempty"` Object string `json:"object,omitempty" bson:"object,omitempty" mapstructure:"object"`
Caller string `json:"caller,omitempty" bson:"caller,omitempty"` Caller string `json:"caller,omitempty" bson:"caller,omitempty" mapstructure:"caller"`
Attr interface{} `json:"attr,omitempty" bson:"attr,omitempty"` Attr interface{} `json:"attr,omitempty" bson:"attr,omitempty" mapstructure:"attr"`
Tags []string `json:"tags,omitempty" bson:"tags,omitempty"` Tags []string `json:"tags,omitempty" bson:"tags,omitempty" mapstructure:"tags"`
} }
//func convertInterfaceToAny(v interface{}) (*any.Any, error) { //func convertInterfaceToAny(v interface{}) (*any.Any, error) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment