mirror of
https://github.com/minio/minio.git
synced 2025-11-24 03:27:44 -05:00
cache: in writeback mode skip etag verification (#13781)
if the commit is still in pending or failed status This PR also does some minor code cleanup
This commit is contained in:
@@ -808,10 +808,6 @@ func (c *diskCache) GetLockContext(ctx context.Context, bucket, object string) (
|
||||
|
||||
// Caches the object to disk
|
||||
func (c *diskCache) Put(ctx context.Context, bucket, object string, data io.Reader, size int64, rs *HTTPRangeSpec, opts ObjectOptions, incHitsOnly, writeback bool) (oi ObjectInfo, err error) {
|
||||
if !c.diskSpaceAvailable(size) {
|
||||
io.Copy(ioutil.Discard, data)
|
||||
return oi, errDiskFull
|
||||
}
|
||||
cLock, lkctx, err := c.GetLockContext(ctx, bucket, object)
|
||||
if err != nil {
|
||||
return oi, err
|
||||
|
||||
Reference in New Issue
Block a user