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
avoid slice out of bounds
Chris Luf177cec50966
diff --git a/weed/filesys/dirty_page.go b/weed/filesys/dirty_page.goindex 8779326100..f4e47950ea 100644--- a/weed/filesys/dirty_page.go+++ b/weed/filesys/dirty_page.go@@ -139,7 +139,7 @@ func (pages *ContinuousDirtyPages) saveToStorage(ctx context.Context, buf []byte}fileUrl := fmt.Sprintf("http://%s/%s", host, fileId)- bufReader := bytes.NewReader(pages.Data[:pages.Size])+ bufReader := bytes.NewReader(buf)uploadResult, err := operation.Upload(fileUrl, pages.f.Name, bufReader, false, "application/octet-stream", nil, "")if err != nil {glog.V(0).Infof("upload data %v to %s: %v", pages.f.Name, fileUrl, err)