public T fromServerExtendedStatus(ServerExtendedStatus in) { return this .taskState(in.getTaskState()) .vmState(in.getVmState()) .powerState(in.getPowerState()); } }
public T fromServerExtendedStatus(ServerExtendedStatus in) { return this .taskState(in.getTaskState()) .vmState(in.getVmState()) .powerState(in.getPowerState()); } }
public T fromServerExtendedStatus(ServerExtendedStatus in) { return this .taskState(in.getTaskState()) .vmState(in.getVmState()) .powerState(in.getPowerState()); } }
public T fromServerExtendedStatus(ServerExtendedStatus in) { return this .taskState(in.getTaskState()) .vmState(in.getVmState()) .powerState(in.getPowerState()); } }
public T fromServerExtendedStatus(ServerExtendedStatus in) { return this .taskState(in.getTaskState()) .vmState(in.getVmState()) .powerState(in.getPowerState()); } }
public T fromServerExtendedStatus(ServerExtendedStatus in) { return this .taskState(in.getTaskState()) .vmState(in.getVmState()) .powerState(in.getPowerState()); } }
/** * Will block until the requested server is in the correct state, if Extended Server Status extension is loaded * this will continue to block while any task is in progress. */ protected void blockUntilServerInState(String serverId, ServerApi api, Status status) { Server currentDetails = null; for (currentDetails = api.get(serverId); currentDetails.getStatus() != status || ((currentDetails.getExtendedStatus().isPresent() && currentDetails.getExtendedStatus().get() .getTaskState() != null)); currentDetails = api.get(serverId)) { System.out.printf("blocking on status %s%n%s%n", status, currentDetails); try { Thread.sleep(5 * 1000); } catch (InterruptedException e) { throw Throwables.propagate(e); } } }
/** * Will block until the requested server is in the correct state, if Extended Server Status extension is loaded * this will continue to block while any task is in progress. */ protected void blockUntilServerInState(String serverId, ServerApi api, Status status) { Server currentDetails = null; for (currentDetails = api.get(serverId); currentDetails.getStatus() != status || ((currentDetails.getExtendedStatus().isPresent() && currentDetails.getExtendedStatus().get() .getTaskState() != null)); currentDetails = api.get(serverId)) { System.out.printf("blocking on status %s%n%s%n", status, currentDetails); try { Thread.sleep(15 * 1000); } catch (InterruptedException e) { throw Throwables.propagate(e); } } }