String.format("Task '%s' must reach status %s", task.getOperationName(), running));
}
protected boolean taskDoneEventually(Task task) {
TaskApi taskApi = context.getApi().getTaskApi();
TaskStatusEquals predicate = new TaskStatusEquals(taskApi, ImmutableSet.of(Task.Status.ABORTED,
Task.Status.CANCELED, Task.Status.ERROR, Task.Status.SUCCESS), ImmutableSet.<Task.Status> of());
return retry(predicate, TASK_TIMEOUT_SECONDS * 1000L).apply(task);
}