Decide whether deleting the specified replica of the block still makes the block
conform to the conf
Check if we can use delHint.
Add localMachine and related nodes to excludedNodes for next replica choosing.
In sub class, we can
Choose a datanode from the given scope with specified storage type.
Choose one node from the rack that localMachine is on. if no such node is
available, choose one node
Choose localMachine as the target. if localMachine is not available, choose a
node on the same rack
Randomly choose numOfReplicas targets from the given scope.
Choose numOfReplicas nodes from the racks that localMachine is NOT on. if not
enough nodes are avail
Calculate the maximum number of replicas to allocate per rack. It also limits
the total number of re