go fmt
This commit is contained in:
@@ -151,4 +151,3 @@ func (f *Filer) deleteChunksIfNotNew(oldEntry, newEntry *Entry) {
|
|||||||
}
|
}
|
||||||
f.DeleteChunks(toDelete)
|
f.DeleteChunks(toDelete)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -79,7 +79,6 @@ func (iam *IdentityAccessManagement) loadS3ApiConfigurationFromBytes(content []b
|
|||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
func (iam *IdentityAccessManagement) loadS3ApiConfiguration(config *iam_pb.S3ApiConfiguration) error {
|
func (iam *IdentityAccessManagement) loadS3ApiConfiguration(config *iam_pb.S3ApiConfiguration) error {
|
||||||
var identities []*Identity
|
var identities []*Identity
|
||||||
for _, ident := range config.Identities {
|
for _, ident := range config.Identities {
|
||||||
|
|||||||
@@ -7,4 +7,3 @@ const (
|
|||||||
ACTION_TAGGING = "Tagging"
|
ACTION_TAGGING = "Tagging"
|
||||||
ACTION_LIST = "List"
|
ACTION_LIST = "List"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|||||||
@@ -175,7 +175,7 @@ func moveAwayOneEcVolume(commandEnv *CommandEnv, ecShardInfo *master_pb.VolumeEc
|
|||||||
|
|
||||||
func moveAwayOneNormalVolume(commandEnv *CommandEnv, volumeReplicas map[uint32][]*VolumeReplica, vol *master_pb.VolumeInformationMessage, thisNode *Node, otherNodes []*Node, applyChange bool) (hasMoved bool, err error) {
|
func moveAwayOneNormalVolume(commandEnv *CommandEnv, volumeReplicas map[uint32][]*VolumeReplica, vol *master_pb.VolumeInformationMessage, thisNode *Node, otherNodes []*Node, applyChange bool) (hasMoved bool, err error) {
|
||||||
sort.Slice(otherNodes, func(i, j int) bool {
|
sort.Slice(otherNodes, func(i, j int) bool {
|
||||||
return otherNodes[i].localVolumeRatio(capacityByMaxVolumeCount) + otherNodes[i].localVolumeRatio(capacityByMaxSsdVolumeCount) < otherNodes[j].localVolumeRatio(capacityByMaxVolumeCount) + otherNodes[j].localVolumeRatio(capacityByMaxSsdVolumeCount)
|
return otherNodes[i].localVolumeRatio(capacityByMaxVolumeCount)+otherNodes[i].localVolumeRatio(capacityByMaxSsdVolumeCount) < otherNodes[j].localVolumeRatio(capacityByMaxVolumeCount)+otherNodes[j].localVolumeRatio(capacityByMaxSsdVolumeCount)
|
||||||
})
|
})
|
||||||
|
|
||||||
for i := 0; i < len(otherNodes); i++ {
|
for i := 0; i < len(otherNodes); i++ {
|
||||||
|
|||||||
@@ -92,7 +92,7 @@ func (v *Volume) load(alsoLoadIndex bool, createDatIfMissing bool, needleMapKind
|
|||||||
if err == nil && alsoLoadIndex {
|
if err == nil && alsoLoadIndex {
|
||||||
// adjust for existing volumes with .idx together with .dat files
|
// adjust for existing volumes with .idx together with .dat files
|
||||||
if v.dirIdx != v.dir {
|
if v.dirIdx != v.dir {
|
||||||
if util.FileExists(v.DataFileName()+".idx") {
|
if util.FileExists(v.DataFileName() + ".idx") {
|
||||||
v.dirIdx = v.dir
|
v.dirIdx = v.dir
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user