Apply .gitignore rules

This commit is contained in:
皮蛋13361098506
2025-01-06 16:21:36 +08:00
parent 1b77f62820
commit ccd2c530cf
580 changed files with 69806 additions and 0 deletions

View File

@@ -0,0 +1,35 @@
package logUtilPlus
import (
"testing"
"time"
)
func TestWrite(t *testing.T) {
Start("http://10.254.0.242:9200", "20008_gs_log", 20008)
InfoLog("日志测试")
WarnLog("日志测试")
DebugLog("日志测试")
ErrorLog("日志测试")
FatalLog("日志测试")
time.Sleep(1 * time.Second)
Stop()
}
func BenchmarkWrite(b *testing.B) {
Start("http://10.254.0.242:9200", "20008_gs_log", 20008)
b.ResetTimer()
for i := 0; i < b.N; i++ {
InfoLog("日志测试%d", i)
WarnLog("日志测试%d", i)
DebugLog("日志测试%d", i)
ErrorLog("日志测试%d", i)
FatalLog("日志测试%d", i)
}
b.StopTimer()
time.Sleep(1 * time.Second)
Stop()
}