public CoordinatorStatus getCoordinator(String instanceId) { if (coordinatorStatus.getInstanceId().equals(instanceId)) { return status(); } return coordinators.get(instanceId); }
@Override public boolean apply(@Nullable CoordinatorStatus coordinatorStatus) { return coordinatorStatus != null && predicate.apply(coordinatorStatus.getInstanceId()); } }
String instanceId = instance.getInstanceId(); if (instanceId.equals(this.coordinatorStatus.getInstanceId())) { throw new IllegalStateException("Provisioner created a coordinator with the same is as this coordinator");
if (instance.getInstanceId().equals(this.coordinatorStatus.getInstanceId())) { continue;
public CoordinatorStatusRepresentation create(CoordinatorStatus status) { return new CoordinatorStatusRepresentation( status.getCoordinatorId(), safeTruncate(status.getCoordinatorId(), shortIdPrefixSize), status.getInstanceId(), status.getState(), status.getInternalUri(), status.getExternalUri(), status.getLocation(), trimLeadingSegments(status.getLocation(), '/', commonLocationParts), status.getInstanceType(), status.getVersion()); } }