My main problem is I see an error in the logs that is not actually an error, it's the desired behaviour, to skip the backend request.
Code snippet of current implementation:
// If no module matches, skip the request and return an empty response
logger.Debug(fmt.Sprintf("[PLUGIN]: Module '%s' not found in 'Modules' header. Skipping request.", expectedModule))
return nil, HTTPResponseError{Code: 412, Msg: "Module not needed for backend call"}
//
Logs:
▶ DEBUG [PLUGIN]: Module '#postman-1#' not found in 'Modules' header. Skipping request.
2025-04-25 12:52:22 [KRAKEND] 2025/04/25 - 10:52:22.498 ▶ ERROR [ENDPOINT: /v2/:country/home/anonymous] Error #0: Module not needed for backend call
2025-04-25 12:52:22 [GIN] 2025/04/25 - 10:52:22 | 200 | 459.178872ms | 172.18.0.1 | GET "/v2/ES/home/anonymous"
2025-04-25 12:52:22 Error #01: Module not needed for backend call