aboutsummaryrefslogtreecommitdiff
path: root/weed/filer
diff options
context:
space:
mode:
authorChris Lu <chris.lu@gmail.com>2021-03-16 00:33:14 -0700
committerChris Lu <chris.lu@gmail.com>2021-03-16 00:33:14 -0700
commit4b1ed227d12323ab3f3c67a0b39967c84a053bc4 (patch)
tree3f5b27fa912efe8ae8ecb33716dcf5c5074d93b1 /weed/filer
parent10164d0386460c1c39ed8b5ee5c434704a2b28fd (diff)
downloadseaweedfs-4b1ed227d12323ab3f3c67a0b39967c84a053bc4.tar.xz
seaweedfs-4b1ed227d12323ab3f3c67a0b39967c84a053bc4.zip
revert fasthttp changes
related to https://github.com/chrislusf/seaweedfs/issues/1907
Diffstat (limited to 'weed/filer')
-rw-r--r--weed/filer/filechunk_manifest.go2
-rw-r--r--weed/filer/read_write.go2
-rw-r--r--weed/filer/stream.go2
3 files changed, 3 insertions, 3 deletions
diff --git a/weed/filer/filechunk_manifest.go b/weed/filer/filechunk_manifest.go
index 99a62c90c..845bfaec1 100644
--- a/weed/filer/filechunk_manifest.go
+++ b/weed/filer/filechunk_manifest.go
@@ -102,7 +102,7 @@ func retriedFetchChunkData(urlStrings []string, cipherKey []byte, isGzipped bool
for waitTime := time.Second; waitTime < util.RetryWaitTime; waitTime += waitTime / 2 {
for _, urlString := range urlStrings {
- shouldRetry, err = util.FastReadUrlAsStream(urlString+"?readDeleted=true", cipherKey, isGzipped, isFullChunk, offset, size, func(data []byte) {
+ shouldRetry, err = util.ReadUrlAsStream(urlString+"?readDeleted=true", cipherKey, isGzipped, isFullChunk, offset, size, func(data []byte) {
buffer.Write(data)
})
if !shouldRetry {
diff --git a/weed/filer/read_write.go b/weed/filer/read_write.go
index 7a6da3beb..1f78057ef 100644
--- a/weed/filer/read_write.go
+++ b/weed/filer/read_write.go
@@ -35,7 +35,7 @@ func ReadContent(filerAddress string, dir, name string) ([]byte, error) {
target := fmt.Sprintf("http://%s%s/%s", filerAddress, dir, name)
- data, _, err := util.FastGet(target)
+ data, _, err := util.Get(target)
return data, err
}
diff --git a/weed/filer/stream.go b/weed/filer/stream.go
index 573ab65e8..42b4070d8 100644
--- a/weed/filer/stream.go
+++ b/weed/filer/stream.go
@@ -185,7 +185,7 @@ func (c *ChunkStreamReader) fetchChunkToBuffer(chunkView *ChunkView) error {
var buffer bytes.Buffer
var shouldRetry bool
for _, urlString := range urlStrings {
- shouldRetry, err = util.FastReadUrlAsStream(urlString, chunkView.CipherKey, chunkView.IsGzipped, chunkView.IsFullChunk(), chunkView.Offset, int(chunkView.Size), func(data []byte) {
+ shouldRetry, err = util.ReadUrlAsStream(urlString, chunkView.CipherKey, chunkView.IsGzipped, chunkView.IsFullChunk(), chunkView.Offset, int(chunkView.Size), func(data []byte) {
buffer.Write(data)
})
if !shouldRetry {