Search in sources :

Example 1 with HostFenceActionExecutor

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

the class GetFenceAgentStatusQuery method executeQueryCommand.

@Override
protected void executeQueryCommand() {
    HostFenceActionExecutor executor = new HostFenceActionExecutor(getHost());
    FenceOperationResult result = executor.getFenceAgentStatus(getParameters().getAgent());
    getQueryReturnValue().setSucceeded(result.getStatus() == Status.SUCCESS);
    getQueryReturnValue().setReturnValue(result);
}
Also used : FenceOperationResult(org.ovirt.engine.core.common.businessentities.pm.FenceOperationResult) HostFenceActionExecutor(org.ovirt.engine.core.bll.pm.HostFenceActionExecutor)

Example 2 with HostFenceActionExecutor

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

the class InitVdsOnUpCommand method processFence.

private void processFence() {
    vdsProxyFound = new FenceProxyLocator(getVds()).isProxyHostAvailable();
    if (getVds().isPmEnabled() && vdsProxyFound) {
        HostFenceActionExecutor executor = new HostFenceActionExecutor(getVds());
        fenceStatusResult = executor.fence(FenceActionType.STATUS);
        fenceSucceeded = fenceStatusResult.getStatus() == Status.SUCCESS;
    }
}
Also used : HostFenceActionExecutor(org.ovirt.engine.core.bll.pm.HostFenceActionExecutor) FenceProxyLocator(org.ovirt.engine.core.bll.pm.FenceProxyLocator)

Example 3 with HostFenceActionExecutor

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

the class GetVdsFenceStatusQuery method executeQueryCommand.

@Override
protected void executeQueryCommand() {
    VDS vds = vdsDao.get(getParameters().getId());
    HostFenceActionExecutor executor = new HostFenceActionExecutor(vds);
    getQueryReturnValue().setReturnValue(executor.fence(FenceActionType.STATUS));
}
Also used : VDS(org.ovirt.engine.core.common.businessentities.VDS) HostFenceActionExecutor(org.ovirt.engine.core.bll.pm.HostFenceActionExecutor)

Aggregations

HostFenceActionExecutor (org.ovirt.engine.core.bll.pm.HostFenceActionExecutor)3 FenceProxyLocator (org.ovirt.engine.core.bll.pm.FenceProxyLocator)1 VDS (org.ovirt.engine.core.common.businessentities.VDS)1 FenceOperationResult (org.ovirt.engine.core.common.businessentities.pm.FenceOperationResult)1