mirror of
https://github.com/minio/minio.git
synced 2025-11-07 21:02:58 -05:00
fix: tweak read buffer size to reduce over-reading (#16338)
This commit is contained in:
@@ -1796,15 +1796,9 @@ func (s *xlStorage) ReadFileStream(ctx context.Context, volume, path string, off
|
||||
}
|
||||
|
||||
or := &xioutil.ODirectReader{
|
||||
File: file,
|
||||
SmallFile: false,
|
||||
}
|
||||
|
||||
if length <= smallFileThreshold {
|
||||
or = &xioutil.ODirectReader{
|
||||
File: file,
|
||||
SmallFile: true,
|
||||
}
|
||||
File: file,
|
||||
// Select bigger blocks when reading at least 50% of a big block.
|
||||
SmallFile: length <= xioutil.BlockSizeLarge/2,
|
||||
}
|
||||
|
||||
r := struct {
|
||||
|
||||
Reference in New Issue
Block a user