diff --git a/internal/admin/server.go b/internal/admin/server.go index d3677d1..3efd340 100644 --- a/internal/admin/server.go +++ b/internal/admin/server.go @@ -116,7 +116,9 @@ func (s *Server) run(parentCtx context.Context, addrs chan net.Addr, errs chan e router.Use(middleware.RealIP) } + router.Use(middleware.RequestID) router.Use(middleware.RequestLogger(bouncerChi.NewLogFormatter())) + router.Use(middleware.Recoverer) if s.serverConfig.Sentry.DSN != "" { logger.Info(ctx, "enabling sentry http middleware") diff --git a/internal/proxy/server.go b/internal/proxy/server.go index 862e692..84534ec 100644 --- a/internal/proxy/server.go +++ b/internal/proxy/server.go @@ -121,7 +121,9 @@ func (s *Server) run(parentCtx context.Context, addrs chan net.Addr, errs chan e router.Use(middleware.RealIP) } + router.Use(middleware.RequestID) router.Use(middleware.RequestLogger(bouncerChi.NewLogFormatter())) + router.Use(middleware.Recoverer) if s.serverConfig.Sentry.DSN != "" { logger.Info(ctx, "enabling sentry http middleware")