X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/a07891c7ac7e90ebdf35ae1812ec03c818fe2a67..514fb685c9d835441e0911d9b9499952b6787095:/lib/dispatchcloud/scheduler/sync.go diff --git a/lib/dispatchcloud/scheduler/sync.go b/lib/dispatchcloud/scheduler/sync.go index 99bee484c6..205ee50187 100644 --- a/lib/dispatchcloud/scheduler/sync.go +++ b/lib/dispatchcloud/scheduler/sync.go @@ -61,6 +61,13 @@ func (sch *Scheduler) sync() { // preparing to run a container that // has already been unlocked/requeued. go sch.kill(uuid, fmt.Sprintf("state=%s", ent.Container.State)) + } else if ent.Container.Priority == 0 { + sch.logger.WithFields(logrus.Fields{ + "ContainerUUID": uuid, + "State": ent.Container.State, + "Priority": ent.Container.Priority, + }).Info("container on hold") + sch.queue.Forget(uuid) } case arvados.ContainerStateLocked: if running && !exited.IsZero() && qUpdated.After(exited) { @@ -99,6 +106,7 @@ func (sch *Scheduler) cancel(uuid string, reason string) { func (sch *Scheduler) kill(uuid string, reason string) { sch.pool.KillContainer(uuid, reason) + sch.pool.ForgetContainer(uuid) } func (sch *Scheduler) requeue(ent container.QueueEnt, reason string) {