Add error filter to admin trace API (#7923)

This allows MinIO to have the ability to send back only error trace
This commit is contained in:
poornas
2019-07-19 17:38:26 -07:00
committed by kannappanr
parent 559a59220e
commit 0373a1699b
7 changed files with 42 additions and 8 deletions

View File

@@ -20,6 +20,7 @@
package main
import (
"fmt"
"log"
"github.com/minio/minio/pkg/madmin"
@@ -40,7 +41,9 @@ func main() {
// Start listening on all http trace activity from all servers
// in the minio cluster.
traceCh := madmClnt.Trace(false, doneCh)
allTrace := false
errTrace := false
traceCh := madmClnt.Trace(allTrace, errTrace, doneCh)
for traceInfo := range traceCh {
if traceInfo.Err != nil {
fmt.Println(traceInfo.Err)