diff options
| author | Chris Lu <chris.lu@gmail.com> | 2018-06-23 16:48:19 -0700 |
|---|---|---|
| committer | Chris Lu <chris.lu@gmail.com> | 2018-06-23 16:48:19 -0700 |
| commit | 36999969851063376b97a05376c6e2596546eb98 (patch) | |
| tree | 040a70f1134a5b4d217f0d12d414f6502a78c35b /weed/storage/volume.go | |
| parent | 00fbca99dc795174b47740acb7507d93a837db22 (diff) | |
| download | seaweedfs-36999969851063376b97a05376c6e2596546eb98.tar.xz seaweedfs-36999969851063376b97a05376c6e2596546eb98.zip | |
add compaction test
Diffstat (limited to 'weed/storage/volume.go')
| -rw-r--r-- | weed/storage/volume.go | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/weed/storage/volume.go b/weed/storage/volume.go index a58a74340..3b03b7c83 100644 --- a/weed/storage/volume.go +++ b/weed/storage/volume.go @@ -29,6 +29,7 @@ type Volume struct { } func NewVolume(dirname string, collection string, id VolumeId, needleMapKind NeedleMapType, replicaPlacement *ReplicaPlacement, ttl *TTL, preallocate int64) (v *Volume, e error) { + // if replicaPlacement is nil, the superblock will be loaded from disk v = &Volume{dir: dirname, Collection: collection, Id: id} v.SuperBlock = SuperBlock{ReplicaPlacement: replicaPlacement, Ttl: ttl} v.needleMapKind = needleMapKind |
