Remove timeout from putobject and listobjects (#9986)

Use a separate client for these calls that can take a long time.

Add request context to these so they are canceled when the client 
disconnects instead except for ListObject which doesn't have any equivalent.
This commit is contained in:
Klaus Post
2020-07-07 12:19:57 -07:00
committed by GitHub
parent 93e7e4a0e5
commit aa4d1021eb
3 changed files with 31 additions and 7 deletions

View File

@@ -406,7 +406,7 @@ func (web *webAPIHandlers) ListObjects(r *http.Request, args *ListObjectsArgs, r
}
return toJSONError(ctx, err, args.BucketName)
}
core, err := getRemoteInstanceClient(r, getHostFromSrv(sr))
core, err := getRemoteInstanceClientLongTimeout(r, getHostFromSrv(sr))
if err != nil {
return toJSONError(ctx, err, args.BucketName)
}