Skip to content

Commit

Permalink
api: don't log requests to health endpoint (#70)
Browse files Browse the repository at this point in the history
  • Loading branch information
worm-emoji authored Sep 7, 2022
1 parent d7d3789 commit cf005c6
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions api/api.go
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,11 @@ func versionHandler(h http.Handler, sha string) http.Handler {

func tracingHandler(env, service, sha string, h http.Handler) http.Handler {
return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
if r.URL.Path == "/health" {
h.ServeHTTP(w, r)
return
}

span, ctx := tracing.SpanFromContext(r.Context(), "http.request")

defer span.Finish()
Expand Down

1 comment on commit cf005c6

@vercel
Copy link

@vercel vercel bot commented on cf005c6 Sep 7, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

lanyard – ./

lanyard-git-main.context.wtf
allowlist.context.wtf
lanyard.context.wtf

Please sign in to comment.