public synchronized void setDiskState(HardwareState state, boolean allowChangesThroughClusterMap) {
    this.allowChangesThroughClustermap = allowChangesThroughClusterMap;
    this.state = state;
  }
Forcibly set disk state {@link HardwareState} and specify whether ClusterMap is allowed to change disk state.
@param state the hardware state of disk
@param allowChangesThroughClusterMap whether the ClusterMap is allowed to change disk state
ambry-test-utils/src/main/java/com/github/ambry/clustermap/MockDiskId.java