mirror of
https://github.com/minio/minio.git
synced 2025-11-07 04:42:56 -05:00
Purge stale object cache entry (#2770)
This commit is contained in:
committed by
Harshavardhana
parent
27e474b3d2
commit
669783f875
@@ -121,7 +121,7 @@ func (xl xlObjects) GetObject(bucket, object string, startOffset int64, length i
|
||||
if xlMeta.Stat.Size > 0 && xl.objCacheEnabled {
|
||||
// Validate if we have previous cache.
|
||||
var cachedBuffer io.ReadSeeker
|
||||
cachedBuffer, err = xl.objCache.Open(path.Join(bucket, object))
|
||||
cachedBuffer, err = xl.objCache.Open(path.Join(bucket, object), modTime)
|
||||
if err == nil { // Cache hit.
|
||||
// Advance the buffer to offset as if it was read.
|
||||
if _, err = cachedBuffer.Seek(startOffset, 0); err != nil { // Seek to the offset.
|
||||
|
||||
Reference in New Issue
Block a user