public void addTokenRangeToCurrentBatchForCluster ( String cluster , String placement , Collection < ScanRange > ranges ) { PlanBatch batch = _clusterTails . get ( cluster ) ; if ( batch == null ) { batch = new PlanBatch ( ) ; _clusterHeads . put ( cluster , batch ) ; _clusterTails . put ( cluster , batch ) ; } batch . addPlanItem ( new PlanItem ( placement , ranges ) ) ; }
Adds a collection of scan ranges to the plan for a specific placement . The range collection should all belong to a single token range in the ring .