Resource reservedResourceClone = Resources.clone( attemptResourceUsage.getReserved()); Resource cluster = rmContext.getScheduler().getClusterResource(); ResourceCalculator calc = rmContext.getScheduler().getResourceCalculator();
when(csContext.getClusterResource()).thenReturn( Resources.createResource(100 * 16 * GB, 100 * 32)); when(scheduler.getClusterResource()).thenReturn( Resources.createResource(125 * GB, 125)); when(csContext.getResourceCalculator()).thenReturn(
when(csContext.getClusterResource()).thenReturn( Resources.createResource(100 * 16 * GB, 100 * 32)); when(scheduler.getClusterResource()).thenReturn( Resources.createResource(125 * GB, 125)); when(csContext.getResourceCalculator()).thenReturn(
Resource cluster = rmContext.getScheduler().getClusterResource(); Resource totalPartitionRes = rmContext.getNodeLabelManager().getResourceByLabel(
scheduler.getClusterResource(), 1L, res, scheduler.getMinimumResourceCapability(), maxAlloc, "dedicated", null, isMove);
privateDispatcher.await(); Resource clusterResource = rm.getResourceScheduler().getClusterResource(); Assert.assertEquals("Initial cluster resources don't match", capability, clusterResource); privateDispatcher.await(); Assert.assertEquals("Cluster resources don't match", newCapability, rm.getResourceScheduler().getClusterResource()); privateResourceTrackerService.stop(); } finally {
scheduler.getClusterResource(), 1L, res, scheduler.getMinimumResourceCapability(), maxAlloc, "dedicated", null, isMove, context);
privateDispatcher.await(); Resource clusterResource = rm.getResourceScheduler().getClusterResource(); Assert.assertEquals("Initial cluster resources don't match", capability, clusterResource); privateDispatcher.await(); Assert.assertEquals("Cluster resources don't match", newCapability, rm.getResourceScheduler().getClusterResource()); privateResourceTrackerService.stop(); } finally {