Alex Meijer 1 месяц назад
Родитель
Сommit
df12063922
1 измененных файлов с 6 добавлено и 0 удалено
  1. 6 0
      core/pkg/storage/s3storage.go

+ 6 - 0
core/pkg/storage/s3storage.go

@@ -663,6 +663,12 @@ type s3ChunkReader struct {
 	fetch     func(off, length int64) ([]byte, error)
 }
 
+
+// s3 chunk reader has following features over minio: 
+// It enforces fixed-size ranged reads (defaultS3ReadChunkSize) instead of one long-lived stream.
+// It keeps error mapping consistent (DoesNotExistError, range validation, SSE options via getRange()).
+// It gives predictable io.Reader semantics around EOF/partial reads while hiding S3 range mechanics.
+//
 func newS3ChunkReader(size, chunkSize int64, fetch func(off, length int64) ([]byte, error)) io.ReadCloser {
 	if chunkSize <= 0 {
 		chunkSize = defaultS3ReadChunkSize