Skip to content

Commit

Permalink
add changes
Browse files Browse the repository at this point in the history
  • Loading branch information
absolutelightning committed Jan 25, 2024
1 parent e6dbfb8 commit c12c127
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions agent/http.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ import (
"encoding/json"
"fmt"
"io"
"math"
"net"
"net/http"
"net/http/pprof"
Expand Down Expand Up @@ -198,6 +199,8 @@ func (s *HTTPHandlers) handler() http.Handler {
minSize := gziphandler.DefaultMinSize
if pattern == "/v1/agent/monitor" || pattern == "/v1/agent/metrics/stream" {
minSize = 0
} else if pattern == "/v1/operator/autopilot/health" {
minSize = math.MaxInt32
}
gzipWrapper, err := gziphandler.GzipHandlerWithOpts(gziphandler.MinSize(minSize))
if err == nil {
Expand Down

0 comments on commit c12c127

Please sign in to comment.