diff --git a/components/guns/grpc/core.go b/components/guns/grpc/core.go index 30f26f9b8..d38e56faa 100644 --- a/components/guns/grpc/core.go +++ b/components/guns/grpc/core.go @@ -66,14 +66,16 @@ type Gun struct { answLog *zap.Logger } -func DefaultGunConfig() GunConfig { - return GunConfig{ - Target: "default target", - AnswLog: AnswLogConfig{ - Enabled: false, - Path: "answ.log", - Filter: "all", - }, +func DefaultGunConfig() func() GunConfig { + return func() GunConfig { + return GunConfig{ + Target: "default target", + AnswLog: AnswLogConfig{ + Enabled: false, + Path: "answ.log", + Filter: "all", + }, + } } }