Don't mark processes as errNotEnoughResourcesForDeployment when budget has been used up

This commit is contained in:
Ingo Oppermann
2024-07-24 12:54:45 +02:00
parent 28e1325eb2
commit 0a74470d38

View File

@@ -361,7 +361,7 @@ func synchronize(wish map[string]string, want []store.Process, have []node.Proce
}
}
if len(nodeid) != 0 && opBudget > 0 {
if len(nodeid) != 0 {
opStackAdd = append(opStackAdd, processOpAdd{
nodeid: nodeid,
config: wantP.Config,
@@ -383,6 +383,10 @@ func synchronize(wish map[string]string, want []store.Process, have []node.Proce
err: errNotEnoughResourcesForDeployment,
})
}
if opBudget <= 0 {
break
}
}
opStack = append(opStack, opStackDelete...)