高热共公日志库
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

16 lines
324 B

  1. package grlogs
  2. import (
  3. _ "golib.gaore.com/GaoreGo/grlogs/logs/es"
  4. "testing"
  5. "time"
  6. )
  7. func TestGetLogger(t *testing.T) {
  8. l := Get("nds", 128).SetAdapter(LevelNone, AdapterElasticSearch)
  9. l.Debug("我正在调试")
  10. l.Critical("出错了")
  11. Get("nds").Warning("hadoee %s", time.Now().Format(time.RFC1123))
  12. l.Flush()
  13. }