diagnostics: AppendUnique(), restructure sets, add metrics, fix bugs

This commit is contained in:
Matthew Holt 2018-02-10 12:59:23 -07:00
parent 703cf7bf8b
commit 6b3c2212a1
No known key found for this signature in database
GPG key ID: 2A349DD577D586A5
10 changed files with 141 additions and 82 deletions

View file

@ -346,7 +346,7 @@ func (s *Server) ServeHTTP(w http.ResponseWriter, r *http.Request) {
}
}()
go diagnostics.AppendUniqueString("user_agent", r.Header.Get("User-Agent"))
go diagnostics.AppendUnique("user_agent", r.Header.Get("User-Agent"))
// copy the original, unchanged URL into the context
// so it can be referenced by middlewares