@Override
  public void onReplicaEvent(ReplicaId replicaId, ReplicaEventType event) {
    if (replicaId instanceof Replica) {
      switch (event) {
        case Disk_Error:
          if (replicaId.getReplicaType() == ReplicaType.DISK_BACKED) {
            ((Disk) replicaId.getDiskId()).onDiskError();
          }
          break;
        case Disk_Ok:
          if (replicaId.getReplicaType() == ReplicaType.DISK_BACKED) {
            ((Disk) replicaId.getDiskId()).onDiskOk();
          }
          break;
        case Node_Timeout:
          ((DataNode) replicaId.getDataNodeId()).onNodeTimeout();
          break;
        case Node_Response:
          ((DataNode) replicaId.getDataNodeId()).onNodeResponse();
          break;
        case Partition_ReadOnly:
          ((Partition) replicaId.getPartitionId()).onPartitionReadOnly();
          break;
        case Replica_Unavailable:
          ((Replica) replicaId).onReplicaUnavailable();
          break;
        case Replica_Available:
          ((Replica) replicaId).onReplicaResponse();
          break;
      }
    }
  }
Add a set of replicas on a new datacenter for an existing partition.

@param partitionId The partition to add to the new datacenter
@param dataCenterName The name of the new datacenter
@param attemptNonRackAwareOnFailure {@code true} if a non rack-aware allocation should be attempted if a rack-aware one
                           is not possible.
ambry-clustermap/src/main/java/com/github/ambry/clustermap/StaticClusterManager.java