Search in sources :

Example 1 with RestartVdsVmsOperation

use of org.ovirt.engine.core.bll.RestartVdsVmsOperation in project ovirt-engine by oVirt.

the class StartVdsCommand method handleSpecificCommandActions.

@Override
protected void handleSpecificCommandActions() {
    RestartVdsVmsOperation restartVmsOper = new RestartVdsVmsOperation(getContext(), getVds());
    restartVmsOper.restartVms(getVmList());
}
Also used : RestartVdsVmsOperation(org.ovirt.engine.core.bll.RestartVdsVmsOperation)

Example 2 with RestartVdsVmsOperation

use of org.ovirt.engine.core.bll.RestartVdsVmsOperation in project ovirt-engine by oVirt.

the class VdsKdumpDetectionCommand method restartVdsVms.

private void restartVdsVms() {
    List<VM> vms = vmDao.getAllRunningForVds(getVdsId());
    if (!vms.isEmpty()) {
        RestartVdsVmsOperation restartVmsOper = new RestartVdsVmsOperation(getContext(), getVds());
        restartVmsOper.restartVms(vms);
        runVdsCommand(VDSCommandType.UpdateVdsVMsCleared, new UpdateVdsVMsClearedVDSCommandParameters(getVds().getId()));
    }
}
Also used : RestartVdsVmsOperation(org.ovirt.engine.core.bll.RestartVdsVmsOperation) VM(org.ovirt.engine.core.common.businessentities.VM) UpdateVdsVMsClearedVDSCommandParameters(org.ovirt.engine.core.common.vdscommands.UpdateVdsVMsClearedVDSCommandParameters)

Example 3 with RestartVdsVmsOperation

use of org.ovirt.engine.core.bll.RestartVdsVmsOperation in project ovirt-engine by oVirt.

the class StopVdsCommand method handleSpecificCommandActions.

@Override
protected void handleSpecificCommandActions() {
    List<VM> vmList = getVmList();
    if (vmList.size() > 0) {
        RestartVdsVmsOperation restartVmsOper = new RestartVdsVmsOperation(getContext(), getVds());
        restartVmsOper.restartVms(vmList);
        runVdsCommand(VDSCommandType.UpdateVdsVMsCleared, new UpdateVdsVMsClearedVDSCommandParameters(getVds().getId()));
    }
}
Also used : RestartVdsVmsOperation(org.ovirt.engine.core.bll.RestartVdsVmsOperation) VM(org.ovirt.engine.core.common.businessentities.VM) UpdateVdsVMsClearedVDSCommandParameters(org.ovirt.engine.core.common.vdscommands.UpdateVdsVMsClearedVDSCommandParameters)

Aggregations

RestartVdsVmsOperation (org.ovirt.engine.core.bll.RestartVdsVmsOperation)3 VM (org.ovirt.engine.core.common.businessentities.VM)2 UpdateVdsVMsClearedVDSCommandParameters (org.ovirt.engine.core.common.vdscommands.UpdateVdsVMsClearedVDSCommandParameters)2