aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChris Lu <chris.lu@gmail.com>2018-12-27 13:10:46 -0800
committerChris Lu <chris.lu@gmail.com>2018-12-27 13:10:46 -0800
commit2a19511ba848913402b77c2f120ef583b7530a79 (patch)
treebc24029e6c6657db6388b7dc7af8dfb5a2011b94
parentd3660ffce8ec38f8017216bca2e77c0362328c72 (diff)
downloadseaweedfs-2a19511ba848913402b77c2f120ef583b7530a79.tar.xz
seaweedfs-2a19511ba848913402b77c2f120ef583b7530a79.zip
avoid gzip benchmark data
related to https://github.com/chrislusf/seaweedfs/issues/804
-rw-r--r--weed/command/benchmark.go6
1 files changed, 5 insertions, 1 deletions
diff --git a/weed/command/benchmark.go b/weed/command/benchmark.go
index 8b65c8663..d0a1a587a 100644
--- a/weed/command/benchmark.go
+++ b/weed/command/benchmark.go
@@ -213,7 +213,11 @@ func writeFiles(idChan chan int, fileIdLineChan chan string, s *stat) {
for id := range idChan {
start := time.Now()
fileSize := int64(*b.fileSize + random.Intn(64))
- fp := &operation.FilePart{Reader: &FakeReader{id: uint64(id), size: fileSize}, FileSize: fileSize}
+ fp := &operation.FilePart{
+ Reader: &FakeReader{id: uint64(id), size: fileSize},
+ FileSize: fileSize,
+ MimeType: "image/bench", // prevent gzip benchmark content
+ }
ar := &operation.VolumeAssignRequest{
Count: 1,
Collection: *b.collection,