Allow caching on single PutObject (#8100)

This commit is contained in:
poornas
2019-09-05 07:20:16 -07:00
committed by kannappanr
parent 496fba3e9a
commit 29f64355ce
4 changed files with 116 additions and 2 deletions

View File

@@ -1053,6 +1053,9 @@ func (web *webAPIHandlers) Upload(w http.ResponseWriter, r *http.Request) {
}
putObject := objectAPI.PutObject
if web.CacheAPI() != nil {
putObject = web.CacheAPI().PutObject
}
objInfo, err := putObject(context.Background(), bucket, object, pReader, opts)
if err != nil {