Skip to content

Commit ddb9d1f

Browse files
author
v-pashas
committed
Set JSON as default formatter
Signed-off-by: v-pashas <[email protected]>
1 parent 90b2029 commit ddb9d1f

File tree

2 files changed

+2
-2
lines changed
  • cmd/rollouts-controller
  • test/cmd/trafficrouter-plugin-sample

2 files changed

+2
-2
lines changed

cmd/rollouts-controller/main.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ func newCommand() *cobra.Command {
8484
}
8585
setLogLevel(logLevel)
8686
if logFormat != "" {
87-
log.SetFormatter(createFormatter(logFormat))
87+
log.SetFormatter(createFormatter("json"))
8888
}
8989
logutil.SetKLogLogger(log.New())
9090
logutil.SetKLogLevel(klogLevel)

test/cmd/trafficrouter-plugin-sample/main.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ func main() {
2323
logCtx := log.WithFields(log.Fields{"plugin": "trafficrouter"})
2424

2525
setLogLevel("debug")
26-
log.SetFormatter(createFormatter("text"))
26+
log.SetFormatter(createFormatter("json"))
2727

2828
rpcPluginImp := &plugin.RpcPlugin{
2929
LogCtx: logCtx,

0 commit comments

Comments
 (0)