fix(region): storage add unmount status

This commit is contained in:
ioito
2021-12-29 17:30:21 +08:00
parent 889c94196c
commit 9781a06bc3
4 changed files with 21 additions and 17 deletions

View File

@@ -93,7 +93,7 @@ func (p *DiskSchedtagPredicate) IsResourceMatchInput(input ISchedtagCustomer, re
func (p *DiskSchedtagPredicate) IsResourceFitInput(u *core.Unit, c core.Candidater, res ISchedtagCandidateResource, input ISchedtagCustomer) core.PredicateFailureReason {
storage := res.(*api.CandidateStorage)
if storage.Status == computeapi.STORAGE_OFFLINE || storage.Enabled.IsFalse() {
if storage.Status != computeapi.STORAGE_ONLINE || storage.Enabled.IsFalse() {
return &FailReason{
fmt.Sprintf("Storage status is %s, enable is %v", storage.Status, storage.Enabled),
StorageEnable,