You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@storm.apache.org by ki...@apache.org on 2018/11/08 22:44:06 UTC

[1/3] storm git commit: Fix RAS worker count estimation

Repository: storm
Updated Branches:
  refs/heads/master 19fbfb9ac -> 98ed0a815


Fix RAS worker count estimation


Project: http://git-wip-us.apache.org/repos/asf/storm/repo
Commit: http://git-wip-us.apache.org/repos/asf/storm/commit/8288d41b
Tree: http://git-wip-us.apache.org/repos/asf/storm/tree/8288d41b
Diff: http://git-wip-us.apache.org/repos/asf/storm/diff/8288d41b

Branch: refs/heads/master
Commit: 8288d41b313126ce7a9da7b548801a58da98b7ae
Parents: 19fbfb9
Author: Kishor Patil <kp...@oath.com>
Authored: Tue Nov 6 16:58:31 2018 -0500
Committer: Kishor Patil <kp...@oath.com>
Committed: Tue Nov 6 16:58:31 2018 -0500

----------------------------------------------------------------------
 .../src/main/java/org/apache/storm/utils/ServerUtils.java      | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/storm/blob/8288d41b/storm-server/src/main/java/org/apache/storm/utils/ServerUtils.java
----------------------------------------------------------------------
diff --git a/storm-server/src/main/java/org/apache/storm/utils/ServerUtils.java b/storm-server/src/main/java/org/apache/storm/utils/ServerUtils.java
index 37d9c67..6f65bf7 100644
--- a/storm-server/src/main/java/org/apache/storm/utils/ServerUtils.java
+++ b/storm-server/src/main/java/org/apache/storm/utils/ServerUtils.java
@@ -691,8 +691,10 @@ public class ServerUtils {
 
     public static int getEstimatedWorkerCountForRASTopo(Map<String, Object> topoConf, StormTopology topology)
         throws InvalidTopologyException {
-        return (int) Math.ceil(getEstimatedTotalHeapMemoryRequiredByTopo(topoConf, topology) /
-                               ObjectReader.getDouble(topoConf.get(Config.WORKER_HEAP_MEMORY_MB)));
+        Double defaultWorkerMaxHeap = ObjectReader.getDouble(topoConf.get(Config.WORKER_HEAP_MEMORY_MB));
+        Double topologyWorkerMaxHeap = ObjectReader.getDouble(topoConf.get(Config.TOPOLOGY_WORKER_MAX_HEAP_SIZE_MB));
+        Double maxHeapSize = topologyWorkerMaxHeap != null && topologyWorkerMaxHeap != 0 ? topologyWorkerMaxHeap : defaultWorkerMaxHeap;
+        return (int) Math.ceil(getEstimatedTotalHeapMemoryRequiredByTopo(topoConf, topology) / maxHeapSize);
     }
 
     public static double getEstimatedTotalHeapMemoryRequiredByTopo(Map<String, Object> topoConf, StormTopology topology)


[3/3] storm git commit: Merge branch 'storm3282' of https://github.com/kishorvpatil/incubator-storm into storm3282

Posted by ki...@apache.org.
Merge branch 'storm3282' of https://github.com/kishorvpatil/incubator-storm into storm3282


Project: http://git-wip-us.apache.org/repos/asf/storm/repo
Commit: http://git-wip-us.apache.org/repos/asf/storm/commit/98ed0a81
Tree: http://git-wip-us.apache.org/repos/asf/storm/tree/98ed0a81
Diff: http://git-wip-us.apache.org/repos/asf/storm/diff/98ed0a81

Branch: refs/heads/master
Commit: 98ed0a8157837e909203371fa2f4f75fac367a0f
Parents: 19fbfb9 2ba69e2
Author: Kishor Patil <kp...@oath.com>
Authored: Thu Nov 8 17:20:39 2018 -0500
Committer: Kishor Patil <kp...@oath.com>
Committed: Thu Nov 8 17:20:39 2018 -0500

----------------------------------------------------------------------
 .../src/main/java/org/apache/storm/utils/ServerUtils.java       | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
----------------------------------------------------------------------



[2/3] storm git commit: Avoid possible illegal Argument

Posted by ki...@apache.org.
Avoid possible illegal Argument


Project: http://git-wip-us.apache.org/repos/asf/storm/repo
Commit: http://git-wip-us.apache.org/repos/asf/storm/commit/2ba69e2e
Tree: http://git-wip-us.apache.org/repos/asf/storm/tree/2ba69e2e
Diff: http://git-wip-us.apache.org/repos/asf/storm/diff/2ba69e2e

Branch: refs/heads/master
Commit: 2ba69e2e4e56bc8207c629d64b1abbe22dccc457
Parents: 8288d41
Author: Kishor Patil <kp...@oath.com>
Authored: Wed Nov 7 11:35:35 2018 -0500
Committer: Kishor Patil <kp...@oath.com>
Committed: Wed Nov 7 11:35:35 2018 -0500

----------------------------------------------------------------------
 .../src/main/java/org/apache/storm/utils/ServerUtils.java     | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/storm/blob/2ba69e2e/storm-server/src/main/java/org/apache/storm/utils/ServerUtils.java
----------------------------------------------------------------------
diff --git a/storm-server/src/main/java/org/apache/storm/utils/ServerUtils.java b/storm-server/src/main/java/org/apache/storm/utils/ServerUtils.java
index 6f65bf7..615aead 100644
--- a/storm-server/src/main/java/org/apache/storm/utils/ServerUtils.java
+++ b/storm-server/src/main/java/org/apache/storm/utils/ServerUtils.java
@@ -691,10 +691,9 @@ public class ServerUtils {
 
     public static int getEstimatedWorkerCountForRASTopo(Map<String, Object> topoConf, StormTopology topology)
         throws InvalidTopologyException {
-        Double defaultWorkerMaxHeap = ObjectReader.getDouble(topoConf.get(Config.WORKER_HEAP_MEMORY_MB));
-        Double topologyWorkerMaxHeap = ObjectReader.getDouble(topoConf.get(Config.TOPOLOGY_WORKER_MAX_HEAP_SIZE_MB));
-        Double maxHeapSize = topologyWorkerMaxHeap != null && topologyWorkerMaxHeap != 0 ? topologyWorkerMaxHeap : defaultWorkerMaxHeap;
-        return (int) Math.ceil(getEstimatedTotalHeapMemoryRequiredByTopo(topoConf, topology) / maxHeapSize);
+        Double defaultWorkerMaxHeap = ObjectReader.getDouble(topoConf.get(Config.WORKER_HEAP_MEMORY_MB), 768d);
+        Double topologyWorkerMaxHeap = ObjectReader.getDouble(topoConf.get(Config.TOPOLOGY_WORKER_MAX_HEAP_SIZE_MB), defaultWorkerMaxHeap);
+        return (int) Math.ceil(getEstimatedTotalHeapMemoryRequiredByTopo(topoConf, topology) / topologyWorkerMaxHeap);
     }
 
     public static double getEstimatedTotalHeapMemoryRequiredByTopo(Map<String, Object> topoConf, StormTopology topology)