private ReplicaId findReplica(PartitionId id) {
    ReplicaId replicaId = null;
    for (ReplicaId replica : id.getReplicaIds()) {
      if (replica.getDataNodeId().equals(dataNodeId)) {
        replicaId = replica;
        break;
      }
    }
    return replicaId;
  }
@param id the {@link PartitionId} to find the {@link ReplicaId} for on the current node
@return the {@link ReplicaId} corresponding to {@code id} on this data node
ambry-server/src/test/java/com/github/ambry/server/AmbryServerRequestsTest.java