protected ReplicaState getReplicaState(ReplicaId replicaId) {
    for (Map.Entry<ReplicaState, List<ReplicaId>> entry : allDcReplicasByState.entrySet()) {
      if (entry.getValue().contains(replicaId)) {
        return entry.getKey();
      }
    }
    throw new IllegalStateException("ReplicaId " + replicaId + " can't find state in " + allDcReplicasByState);
  }
Return the replica state for given replica id.
@param replicaId The replica id
@return Replica state for replica id.
ambry-router/src/main/java/com/github/ambry/router/SimpleOperationTracker.java