diff options
| author | Chris Lu <chris.lu@gmail.com> | 2021-02-12 05:59:52 -0800 |
|---|---|---|
| committer | Chris Lu <chris.lu@gmail.com> | 2021-02-12 05:59:52 -0800 |
| commit | 7d9dc3c6a273e21d719605a650504a30e545b078 (patch) | |
| tree | fdcecf9ba99f7a88cab976c6879c338408e26fc6 /weed/filer/stream.go | |
| parent | 487e435679d6c8cc153b8ef048b8957478cd3d0c (diff) | |
| download | seaweedfs-7d9dc3c6a273e21d719605a650504a30e545b078.tar.xz seaweedfs-7d9dc3c6a273e21d719605a650504a30e545b078.zip | |
use fasthttp lib to read
Diffstat (limited to 'weed/filer/stream.go')
| -rw-r--r-- | weed/filer/stream.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/weed/filer/stream.go b/weed/filer/stream.go index f0042a0ff..075204b79 100644 --- a/weed/filer/stream.go +++ b/weed/filer/stream.go @@ -181,7 +181,7 @@ func (c *ChunkStreamReader) fetchChunkToBuffer(chunkView *ChunkView) error { var buffer bytes.Buffer var shouldRetry bool for _, urlString := range urlStrings { - shouldRetry, err = util.ReadUrlAsStream(urlString+"?readDeleted=true", chunkView.CipherKey, chunkView.IsGzipped, chunkView.IsFullChunk(), chunkView.Offset, int(chunkView.Size), func(data []byte) { + shouldRetry, err = util.FastReadUrlAsStream(urlString+"?readDeleted=true", chunkView.CipherKey, chunkView.IsGzipped, chunkView.IsFullChunk(), chunkView.Offset, int(chunkView.Size), func(data []byte) { buffer.Write(data) }) if !shouldRetry { |
