backend requirements onthe xustomer app

This commit is contained in:
2026-09-07 10:55:11 +05:30
parent 35675d8a9b
commit 1b2690b21a
56 changed files with 13342 additions and 1071 deletions

View File

@@ -167,6 +167,13 @@ func main() {
AllowMethods: "GET,POST,PUT,DELETE,PATCH,OPTIONS",
}))
// Echo X-Request-Id on every response, errors included, minting one when the
// caller did not send it. The customer app funnels every failure into a
// single retryable error state, so without this a support conversation
// about "it failed" has nothing to correlate against the logs. Registered
// before the logger so the id is available to it.
app.Use(middlewares.RequestID())
// Structured Zap logger middleware
app.Use(middlewares.ZapLogger())