/** * Get the total memory reserved. * * @param withUpdatedLimits the local assignment with shared memory * @return the total memory reserved. */ public long getTotalTopologyMemoryReserved(LocalAssignment withUpdatedLimits) { updateMemoryAccounting(); long ret = containerMemoryTracker.getReservedMemoryMb(_topologyId); if (withUpdatedLimits.is_set_total_node_shared()) { ret += withUpdatedLimits.get_total_node_shared(); } return ret; }