From 8ad5597192fa2fbe273912cf729446a7ae0387c0 Mon Sep 17 00:00:00 2001 From: Jonathan Vuillemin Date: Wed, 20 Mar 2024 11:23:00 +0100 Subject: [PATCH] feat(fxcore): Perfs audit --- fxcore/module.go | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/fxcore/module.go b/fxcore/module.go index c75235d..f5ff983 100644 --- a/fxcore/module.go +++ b/fxcore/module.go @@ -165,21 +165,21 @@ func withMiddlewares(coreServer *echo.Echo, p FxCoreParam) *echo.Echo { )) // request logger middleware - requestHeadersToLog := map[string]string{ - httpservermiddleware.HeaderXRequestId: httpservermiddleware.LogFieldRequestId, - } + /* requestHeadersToLog := map[string]string{ + httpservermiddleware.HeaderXRequestId: httpservermiddleware.LogFieldRequestId, + } - for headerName, fieldName := range p.Config.GetStringMapString("modules.core.server.log.headers") { - requestHeadersToLog[headerName] = fieldName - } + for headerName, fieldName := range p.Config.GetStringMapString("modules.core.server.log.headers") { + requestHeadersToLog[headerName] = fieldName + }*/ - coreServer.Use(httpservermiddleware.RequestLoggerMiddlewareWithConfig( + /* coreServer.Use(httpservermiddleware.RequestLoggerMiddlewareWithConfig( httpservermiddleware.RequestLoggerMiddlewareConfig{ RequestHeadersToLog: requestHeadersToLog, RequestUriPrefixesToExclude: p.Config.GetStringSlice("modules.core.server.log.exclude"), LogLevelFromResponseOrErrorCode: p.Config.GetBool("modules.core.server.log.level_from_response"), }, - )) + ))*/ // request tracer middleware if p.Config.GetBool("modules.core.server.trace.enabled") {