SeaweedFS is a distributed storage system for object storage (S3), file systems, Iceberg table buckets, and Lance vector buckets, designed to handle billions of files with O(1) disk access and effortless horizontal scaling.
Go blob-storagecloud-drivedistributed-file-systemdistributed-storageerasure-codingfusehadoop-hdfshdfskuberneteslancelancedbobject-storageposixs3s3-storageseaweedfstiered-file-systemvector-search
Revert "go fmt"
Chris Lu93624635b47b
diff --git a/weed/filer/filechunks_read.go b/weed/filer/filechunks_read.goindex bc05d9821b..b39f6a35cd 100644--- a/weed/filer/filechunks_read.go+++ b/weed/filer/filechunks_read.go@@ -40,7 +40,7 @@ func readResolvedChunks(chunks []*filer_pb.FileChunk) (visibles []VisibleIntervafor _, point := range points {if point.isStart {if len(queue) > 0 {- lastIndex := len(queue) - 1+ lastIndex := len(queue) -1lastPoint := queue[lastIndex]if point.x != prevX && lastPoint.ts < point.ts {visibles = addToVisibles(visibles, prevX, lastPoint, point)diff --git a/weed/filer/filechunks_read_test.go b/weed/filer/filechunks_read_test.goindex 50dda68d1c..1920f51859 100644--- a/weed/filer/filechunks_read_test.go+++ b/weed/filer/filechunks_read_test.go@@ -52,7 +52,7 @@ func TestReadResolvedChunks(t *testing.T) {func TestRandomizedReadResolvedChunks(t *testing.T) {- var limit int64 = 1024 * 1024+ var limit int64 = 1024*1024array := make([]int64, limit)var chunks []*filer_pb.FileChunkfor ts := int64(0); ts < 1024; ts++ {@@ -75,7 +75,7 @@ func TestRandomizedReadResolvedChunks(t *testing.T) {visibles := readResolvedChunks(chunks)for _, visible := range visibles {- for i := visible.start; i < visible.stop; i++ {+ for i := visible.start; i<visible.stop;i++{if array[i] != visible.modifiedTime {t.Errorf("position %d expected ts %d actual ts %d", i, array[i], visible.modifiedTime)}@@ -101,12 +101,12 @@ func randomWrite(array []int64, start int64, size int64, ts int64) *filer_pb.Filfunc TestSequentialReadResolvedChunks(t *testing.T) {- var chunkSize int64 = 1024 * 1024 * 2+ var chunkSize int64 = 1024*1024*2var chunks []*filer_pb.FileChunkfor ts := int64(0); ts < 13; ts++ {chunks = append(chunks, &filer_pb.FileChunk{FileId: "",- Offset: chunkSize * ts,+ Offset: chunkSize*ts,Size: uint64(chunkSize),Mtime: 1,})