Compare commits

...

1 Commits

Author SHA1 Message Date
b829092503 Added WriteTimeout (100ms) 2025-10-12 19:20:48 +02:00

View File

@@ -3,6 +3,7 @@ package fluentd
import (
"fmt"
"log"
"time"
"github.com/fluent/fluent-logger-golang/fluent"
)
@@ -14,9 +15,9 @@ type Logger struct {
func NewLogger(appName, fHost string, fPort int) (*Logger, error) {
config := fluent.Config{
FluentHost: fHost,
FluentPort: fPort,
// WriteTimeout: -1,
FluentHost: fHost,
FluentPort: fPort,
WriteTimeout: 100 * time.Millisecond,
}
fluent, err := fluent.New(config)
if err != nil {