message.go 460 B

123456789101112131415161718192021
  1. package logging
  2. import (
  3. "time"
  4. )
  5. // LogMessage is the event payload for a log message
  6. type LogMessage struct {
  7. ID string
  8. Time time.Time
  9. Level string
  10. Persist bool // used when we want to show the mesage in the status bar
  11. PersistTime time.Duration // used when we want to show the mesage in the status bar
  12. Message string `json:"msg"`
  13. Attributes []Attr
  14. }
  15. type Attr struct {
  16. Key string
  17. Value string
  18. }