You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@storm.apache.org by bo...@apache.org on 2015/11/20 23:26:34 UTC

[09/15] storm git commit: Use camel case to be consistent

Use camel case to be consistent


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

Branch: refs/heads/master
Commit: bac4a053687f1ba8c806f6fe20b9d47f3fba2407
Parents: 71a5b1a
Author: zhuol <zh...@yahoo-inc.com>
Authored: Fri Nov 20 13:05:35 2015 -0600
Committer: zhuol <zh...@yahoo-inc.com>
Committed: Fri Nov 20 13:05:35 2015 -0600

----------------------------------------------------------------------
 .../jvm/backtype/storm/scheduler/Cluster.java   | 24 ++++++++++----------
 1 file changed, 12 insertions(+), 12 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/storm/blob/bac4a053/storm-core/src/jvm/backtype/storm/scheduler/Cluster.java
----------------------------------------------------------------------
diff --git a/storm-core/src/jvm/backtype/storm/scheduler/Cluster.java b/storm-core/src/jvm/backtype/storm/scheduler/Cluster.java
index ff08ad1..571ee1b 100644
--- a/storm-core/src/jvm/backtype/storm/scheduler/Cluster.java
+++ b/storm-core/src/jvm/backtype/storm/scheduler/Cluster.java
@@ -425,7 +425,7 @@ public class Cluster {
         for (String topologyId : this.assignments.keySet()) {
             ret.put(topologyId, this.assignments.get(topologyId));
         }
-        
+
         return ret;
     }
 
@@ -472,22 +472,22 @@ public class Cluster {
     private Double getAssignedMemoryForSlot(Map topConf) {
         Double totalWorkerMemory = 0.0;
 
-        String topology_worker_childopts = Utils.getString(topConf.get(Config.TOPOLOGY_WORKER_CHILDOPTS), null);
-        String worker_childopts = Utils.getString(topConf.get(Config.WORKER_CHILDOPTS), null);
-        Double mem_topology_worker_childopts = Utils.parseWorkerChildOpts(topology_worker_childopts, null);
-        Double mem_worker_childopts = Utils.parseWorkerChildOpts(worker_childopts, null);
+        String topologyWorkerChildopts = Utils.getString(topConf.get(Config.TOPOLOGY_WORKER_CHILDOPTS), null);
+        String workerChildopts = Utils.getString(topConf.get(Config.WORKER_CHILDOPTS), null);
+        Double memTopologyWorkerChildopts = Utils.parseWorkerChildOpts(topologyWorkerChildopts, null);
+        Double memWorkerChildopts = Utils.parseWorkerChildOpts(workerChildopts, null);
 
-        if (mem_topology_worker_childopts != null) {
-            totalWorkerMemory += mem_topology_worker_childopts;
-        } else if (mem_worker_childopts != null) {
-            totalWorkerMemory += mem_worker_childopts;
+        if (memTopologyWorkerChildopts != null) {
+            totalWorkerMemory += memTopologyWorkerChildopts;
+        } else if (memWorkerChildopts != null) {
+            totalWorkerMemory += memWorkerChildopts;
         } else {
             totalWorkerMemory += Utils.getInt(topConf.get(Config.WORKER_HEAP_MEMORY_MB));
         }
 
-        String topology_worker_lw_childiopts = Utils.getString(topConf.get(Config.TOPOLOGY_WORKER_LOGWRITER_CHILDOPTS), null);
-        if (topology_worker_lw_childiopts != null) {
-            totalWorkerMemory += Utils.parseWorkerChildOpts(topology_worker_lw_childiopts, 0.0);
+        String topoWorkerLwChildopts = Utils.getString(topConf.get(Config.TOPOLOGY_WORKER_LOGWRITER_CHILDOPTS), null);
+        if (topoWorkerLwChildopts != null) {
+            totalWorkerMemory += Utils.parseWorkerChildOpts(topoWorkerLwChildopts, 0.0);
         }
         return totalWorkerMemory;
     }