forked from mirror/logrus
Don't disconnect on every Fire()
This commit is contained in:
parent
91f92800d7
commit
dbf7fad1dc
|
@ -29,7 +29,6 @@ func NewPapertrailHook(host string, port int, appName string) (*PapertrailHook,
|
|||
|
||||
// Fire is called when a log event is fired.
|
||||
func (hook *PapertrailHook) Fire(entry *logrus.Entry) error {
|
||||
defer hook.UDPConn.Close()
|
||||
date := time.Now().Format(format)
|
||||
payload := fmt.Sprintf("<22> %s %s: [%s] %s", date, hook.AppName, entry.Data["level"], entry.Message)
|
||||
|
||||
|
|
Loading…
Reference in New Issue