Skip to content

Commit

Permalink
Add swss-common log level support to gnmi (#330)
Browse files Browse the repository at this point in the history
  • Loading branch information
liuh-80 authored Nov 22, 2024
1 parent d77883d commit 2c4b9c8
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions telemetry/telemetry.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ import (
"google.golang.org/grpc"
"google.golang.org/grpc/credentials"
"google.golang.org/grpc/keepalive"
"github.com/sonic-net/sonic-gnmi/swsscommon"
)

type ServerControlValue int
Expand Down Expand Up @@ -88,6 +89,9 @@ func runTelemetry(args []string) error {
return err
}

// enable swss-common debug level
swsscommon.LoggerLinkToDbNative("telemetry")

var wg sync.WaitGroup
// serverControlSignal channel is a channel that will be used to notify gnmi server to start, stop, restart, depending of syscall or cert updates
var serverControlSignal = make(chan ServerControlValue, 1)
Expand Down

0 comments on commit 2c4b9c8

Please sign in to comment.