I have this code to disable client caching for a GET API:
headers := metadata.Pairs(
"Cache-Control", "no-cache, no-store, must-revalidate",
"Pragma", "no-cache",
"Expires", "0",
)
err := grpc.SetHeader(ctx, headers)
When I curl -i
the API, the response shows Cache-Control: no-cache, no-store, must-revalidate
, but not the Pragma or Expires. I think I'm using the right way to set these. Does GRPC not support certain headers?