Skip to content

Commit

Permalink
feat: skip cache handling for health check (#30)
Browse files Browse the repository at this point in the history
  • Loading branch information
Jeff Woo authored Feb 23, 2022
1 parent 498056e commit faaa659
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions bin/v0.34.x/rpc/register.go
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,11 @@ func StartRPC(
// caching middleware
apiSrv.Router.Use(func(next http.Handler) http.Handler {
return http.HandlerFunc(func(writer http.ResponseWriter, request *http.Request) {
if request.URL.Path == "/health" {
next.ServeHTTP(writer, request)
return
}

heightQuery := request.URL.Query().Get("height")
height, err := strconv.ParseInt(heightQuery, 10, 64)

Expand Down

0 comments on commit faaa659

Please sign in to comment.