rename fields

This commit is contained in:
Adrien PONSIN 2025-04-17 13:08:55 +02:00
parent 17c73fb900
commit 7aef361ed2
No known key found for this signature in database
GPG Key ID: 7B4D4A32C05C475E

View File

@ -148,7 +148,7 @@ func Serve(group *errgroup.Group) *cli.Command {
} }
func (ph *ProxyHandler) ServeHTTP(w http.ResponseWriter, r *http.Request) { func (ph *ProxyHandler) ServeHTTP(w http.ResponseWriter, r *http.Request) {
log.Debug().Str("remote_addr", r.RemoteAddr).Str("http_method", r.Method).Str("path", r.URL.Path).Msg("incoming request") log.Debug().Str("remote_addr", r.RemoteAddr).Str("method", r.Method).Str("path", r.URL.Path).Msg("incoming request")
mr, ok := containerMethodRegex["*"] mr, ok := containerMethodRegex["*"]
if ok { if ok {
if err := checkMethodPath(r, mr); err != nil { if err := checkMethodPath(r, mr); err != nil {
@ -176,9 +176,9 @@ func (ph *ProxyHandler) ServeHTTP(w http.ResponseWriter, r *http.Request) {
} }
log.Info(). log.Info().
Str("remote_addr", r.RemoteAddr). Str("remote_addr", r.RemoteAddr).
Str("http_method", r.Method). Str("method", r.Method).
Str("path", r.URL.Path). Str("path", r.URL.Path).
Str("container_name", containerName). Str("from", containerName).
Msg("incoming request matches a registered regular expression") Msg("incoming request matches a registered regular expression")
ph.rp.ServeHTTP(w, r) ph.rp.ServeHTTP(w, r)
return return