Search in sources :

Example 1 with ReduceWorkerAction

use of es.bsc.compss.scheduler.types.allocatableactions.ReduceWorkerAction in project compss by bsc-wdc.

the class TaskScheduler method reduceWorkerResources.

private <T extends WorkerResourceDescription> void reduceWorkerResources(ResourceScheduler<T> worker, ResourceUpdate<T> modification) {
    worker.pendingModification(modification);
    SchedulingInformation schedInfo = generateSchedulingInformation(worker);
    ReduceWorkerAction<T> action = new ReduceWorkerAction<>(schedInfo, worker, this, modification);
    try {
        action.schedule(worker, (Score) null);
        action.tryToLaunch();
    } catch (BlockedActionException | UnassignedActionException | InvalidSchedulingException e) {
    // Can not be blocked nor unassigned
    }
}
Also used : UnassignedActionException(es.bsc.compss.scheduler.exceptions.UnassignedActionException) BlockedActionException(es.bsc.compss.scheduler.exceptions.BlockedActionException) InvalidSchedulingException(es.bsc.compss.scheduler.exceptions.InvalidSchedulingException) ReduceWorkerAction(es.bsc.compss.scheduler.types.allocatableactions.ReduceWorkerAction) SchedulingInformation(es.bsc.compss.scheduler.types.SchedulingInformation)

Aggregations

BlockedActionException (es.bsc.compss.scheduler.exceptions.BlockedActionException)1 InvalidSchedulingException (es.bsc.compss.scheduler.exceptions.InvalidSchedulingException)1 UnassignedActionException (es.bsc.compss.scheduler.exceptions.UnassignedActionException)1 SchedulingInformation (es.bsc.compss.scheduler.types.SchedulingInformation)1 ReduceWorkerAction (es.bsc.compss.scheduler.types.allocatableactions.ReduceWorkerAction)1