feat: add X-Instance-Id header and instance_id log field

This commit is contained in:
kk10
2026-10-17 10:09:31 +03:00
parent cd6a1c7aee
commit dc79ef5e1f
4 changed files with 34 additions and 1 deletions
+2 -1
View File
@@ -27,7 +27,7 @@ func Run() error {
cfg := config.Load()
log := logger.New(cfg.Logging.Level)
log := logger.New(cfg.Logging.Level).With("instance_id", cfg.Server.InstanceID)
dbURL, err := cfg.Database.URL()
if err != nil {
@@ -80,6 +80,7 @@ func Run() error {
router := NewRouter(
log,
cfg.Server.InstanceID,
cfg.Server.MaxInflightRequests,
pool,
authService,