volume: bound the proxy master lookup to the request context

This commit is contained in:
user.email committed 2026-10-26 02:44:02 -07:00
1 parent fdd9c1edd3
commit 561307a7ca
2 files changed
+14 -4

No files matched your search

+1 -1
View File
@@ -65,7 +65,7 @@ func (vs *VolumeServer) proxyReqToTargetServer(w http.ResponseWriter, r *http.Re
w.WriteHeader(http.StatusBadRequest)
return
}
lookupResult, err := operation.LookupVolumeId(vs.GetMaster, vs.grpcDialOption, volumeId.String())
lookupResult, err := operation.LookupVolumeIdWithContext(r.Context(), vs.GetMaster, vs.grpcDialOption, volumeId.String())
if err != nil && vs.ReadMode == "proxy" {
glog.V(0).InfofCtx(r.Context(), "lookup error: %v %s", err, r.URL.Path)
InternalError(w, r, nil)