Github user jerrypeng commented on a diff in the pull request: https://github.com/apache/storm/pull/1016#discussion_r49821113 --- Diff: storm-core/src/jvm/org/apache/storm/scheduler/resource/RAS_Node.java --- @@ -247,19 +253,23 @@ private void freeMemory(double amount) { private void freeCPU(double amount) { LOG.debug("freeing {} CPU on node...avail CPU: {}", amount, getHostname(), _availCPU); - if ((_availCPU + amount) > getAvailableCpuResources()) { - LOG.warn("Freeing more CPU than there exists!"); + if ((_availCPU + amount) > getTotalCpuResources()) { + LOG.warn("Freeing more CPU than there exists! CPU trying to free: {} Total CPU on Node: {}", (_availMemory + amount), getTotalCpuResources()); return; } _availCPU += amount; } + /** + * get the amount of memory used by a worker + */ public double getMemoryUsedByWorker(WorkerSlot ws) { TopologyDetails topo = findTopologyUsingWorker(ws); if (topo == null) { return 0.0; } Collection<ExecutorDetails> execs = getExecutors(ws, _cluster); + LOG.info("getMemoryUsedByWorker executors: {}", execs); --- End diff -- will get rid of
--- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. ---