diff options
| author | Chris Lu <chris.lu@gmail.com> | 2019-12-23 12:48:20 -0800 |
|---|---|---|
| committer | Chris Lu <chris.lu@gmail.com> | 2019-12-23 12:48:20 -0800 |
| commit | 09ca936c78c1044412f47dc06caff1bf08273e60 (patch) | |
| tree | c8402cc969ca53b841bfdcb6ae23d3955a20e5ec /weed/storage/volume_loading.go | |
| parent | dda5c6d3cb32550777f1baf5bd00794e10e56d84 (diff) | |
| download | seaweedfs-09ca936c78c1044412f47dc06caff1bf08273e60.tar.xz seaweedfs-09ca936c78c1044412f47dc06caff1bf08273e60.zip | |
shell: add ec.decode command
Diffstat (limited to 'weed/storage/volume_loading.go')
| -rw-r--r-- | weed/storage/volume_loading.go | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/weed/storage/volume_loading.go b/weed/storage/volume_loading.go index 5c1ac172a..eb177e850 100644 --- a/weed/storage/volume_loading.go +++ b/weed/storage/volume_loading.go @@ -11,11 +11,12 @@ import ( "github.com/chrislusf/seaweedfs/weed/stats" "github.com/chrislusf/seaweedfs/weed/storage/backend" "github.com/chrislusf/seaweedfs/weed/storage/needle" + "github.com/chrislusf/seaweedfs/weed/storage/super_block" ) func loadVolumeWithoutIndex(dirname string, collection string, id needle.VolumeId, needleMapKind NeedleMapType) (v *Volume, err error) { v = &Volume{dir: dirname, Collection: collection, Id: id} - v.SuperBlock = SuperBlock{} + v.SuperBlock = super_block.SuperBlock{} v.needleMapKind = needleMapKind err = v.load(false, false, needleMapKind, 0) return @@ -43,7 +44,7 @@ func (v *Volume) load(alsoLoadIndex bool, createDatIfMissing bool, needleMapKind v.noWriteOrDelete = true } v.lastModifiedTsSeconds = uint64(modifiedTime.Unix()) - if fileSize >= _SuperBlockSize { + if fileSize >= super_block.SuperBlockSize { alreadyHasSuperBlock = true } v.DataBackend = backend.NewDiskFile(dataFile) |
