From 47d01b8a020fd2267db71a2fcc882abe20861e04 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Frederik=20Sch=C3=B6ll?= Date: Fri, 5 Apr 2024 16:15:12 +0200 Subject: [PATCH] print the subgraph deployment id if available as trusted header --- service/tier1.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/service/tier1.go b/service/tier1.go index aacad969e..9dd53c9be 100644 --- a/service/tier1.go +++ b/service/tier1.go @@ -251,6 +251,10 @@ func (s *Tier1Service) Blocks( zap.String("key_id", auth.APIKeyID()), zap.String("ip_address", auth.RealIP()), ) + if auth["x-deployment-id"] != "" { + fields = append(fields, zap.String("deployment_id", auth["x-deployment-id"])) + } + if cacheTag := auth.Get("X-Sf-Substreams-Cache-Tag"); cacheTag != "" { fields = append(fields, zap.String("cache_tag", cacheTag),