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 2014/06/09 15:48:26 UTC

[21/32] git commit: STORM-297: Add a comment about why using java collection directly in clojure

STORM-297: Add a comment about why using java collection directly in clojure


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

Branch: refs/heads/master
Commit: 9f9a2a556986cc67452081f0bd763e3ed1da8f75
Parents: 04b4907
Author: Sean Zhong <cl...@gmail.com>
Authored: Tue May 20 22:23:05 2014 +0800
Committer: Sean Zhong <cl...@gmail.com>
Committed: Tue May 20 22:23:05 2014 +0800

----------------------------------------------------------------------
 storm-core/src/clj/backtype/storm/daemon/worker.clj | 2 ++
 1 file changed, 2 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-storm/blob/9f9a2a55/storm-core/src/clj/backtype/storm/daemon/worker.clj
----------------------------------------------------------------------
diff --git a/storm-core/src/clj/backtype/storm/daemon/worker.clj b/storm-core/src/clj/backtype/storm/daemon/worker.clj
index 437e8dd..4ae7f0a 100644
--- a/storm-core/src/clj/backtype/storm/daemon/worker.clj
+++ b/storm-core/src/clj/backtype/storm/daemon/worker.clj
@@ -119,6 +119,8 @@
         (fast-list-iter [[task tuple :as pair] tuple-batch]
           (if (local-tasks task)
             (.add local pair)
+            
+            ;;Using java objects directly to avoid performance issues in java code
             (let [node+port (get @task->node+port task)]
               (when (not (.get remoteMap node+port))
                 (.put remoteMap node+port (ArrayList.)))