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/03/11 21:28:26 UTC
[1/3] storm git commit: [STORM-663] Create javadocs for BoltDeclarer
Repository: storm
Updated Branches:
refs/heads/master 3a3b7cea7 -> 3113ae1ec
[STORM-663] Create javadocs for BoltDeclarer
Project: http://git-wip-us.apache.org/repos/asf/storm/repo
Commit: http://git-wip-us.apache.org/repos/asf/storm/commit/288cc322
Tree: http://git-wip-us.apache.org/repos/asf/storm/tree/288cc322
Diff: http://git-wip-us.apache.org/repos/asf/storm/diff/288cc322
Branch: refs/heads/master
Commit: 288cc322774721c2e3ae6c84161ec1bd9d3f24b1
Parents: 8036109
Author: lewuathe <le...@me.com>
Authored: Tue Feb 10 22:06:23 2015 +0900
Committer: lewuathe <le...@me.com>
Committed: Tue Feb 10 22:06:23 2015 +0900
----------------------------------------------------------------------
.../backtype/storm/topology/BoltDeclarer.java | 4 +
.../backtype/storm/topology/InputDeclarer.java | 128 +++++++++++++++++++
2 files changed, 132 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/storm/blob/288cc322/storm-core/src/jvm/backtype/storm/topology/BoltDeclarer.java
----------------------------------------------------------------------
diff --git a/storm-core/src/jvm/backtype/storm/topology/BoltDeclarer.java b/storm-core/src/jvm/backtype/storm/topology/BoltDeclarer.java
index ff2ec2d..0c4b200 100644
--- a/storm-core/src/jvm/backtype/storm/topology/BoltDeclarer.java
+++ b/storm-core/src/jvm/backtype/storm/topology/BoltDeclarer.java
@@ -17,6 +17,10 @@
*/
package backtype.storm.topology;
+/**
+ * BoltDeclarer includes grouping APIs for storm topology.
+ * @see <a href="https://storm.apache.org/documentation/Concepts.html">Concepts -Stream groupings-</a>
+ */
public interface BoltDeclarer extends InputDeclarer<BoltDeclarer>, ComponentConfigurationDeclarer<BoltDeclarer> {
}
http://git-wip-us.apache.org/repos/asf/storm/blob/288cc322/storm-core/src/jvm/backtype/storm/topology/InputDeclarer.java
----------------------------------------------------------------------
diff --git a/storm-core/src/jvm/backtype/storm/topology/InputDeclarer.java b/storm-core/src/jvm/backtype/storm/topology/InputDeclarer.java
index ac0848f..ae93c44 100644
--- a/storm-core/src/jvm/backtype/storm/topology/InputDeclarer.java
+++ b/storm-core/src/jvm/backtype/storm/topology/InputDeclarer.java
@@ -24,31 +24,159 @@ import backtype.storm.tuple.Fields;
public interface InputDeclarer<T extends InputDeclarer> {
+ /**
+ * The stream is partitioned by the fields specified in the grouping.
+ * @param componentId
+ * @param fields
+ * @return
+ */
public T fieldsGrouping(String componentId, Fields fields);
+
+ /**
+ * The stream is partitioned by the fields specified in the grouping.
+ * @param componentId
+ * @param streamId
+ * @param fields
+ * @return
+ */
public T fieldsGrouping(String componentId, String streamId, Fields fields);
+ /**
+ * The entire stream goes to a single one of the bolt's tasks.
+ * Specifically, it goes to the task with the lowest id.
+ * @param componentId
+ * @return
+ */
public T globalGrouping(String componentId);
+
+ /**
+ * The entire stream goes to a single one of the bolt's tasks.
+ * Specifically, it goes to the task with the lowest id.
+ * @param componentId
+ * @param streamId
+ * @return
+ */
public T globalGrouping(String componentId, String streamId);
+ /**
+ * Tuples are randomly distributed across the bolt's tasks in a way such that
+ * each bolt is guaranteed to get an equal number of tuples.
+ * @param componentId
+ * @return
+ */
public T shuffleGrouping(String componentId);
+
+ /**
+ * Tuples are randomly distributed across the bolt's tasks in a way such that
+ * each bolt is guaranteed to get an equal number of tuples.
+ * @param componentId
+ * @param streamId
+ * @return
+ */
public T shuffleGrouping(String componentId, String streamId);
+ /**
+ * If the target bolt has one or more tasks in the same worker process,
+ * tuples will be shuffled to just those in-process tasks.
+ * Otherwise, this acts like a normal shuffle grouping.
+ * @param componentId
+ * @return
+ */
public T localOrShuffleGrouping(String componentId);
+
+ /**
+ * If the target bolt has one or more tasks in the same worker process,
+ * tuples will be shuffled to just those in-process tasks.
+ * Otherwise, this acts like a normal shuffle grouping.
+ * @param componentId
+ * @param streamId
+ * @return
+ */
public T localOrShuffleGrouping(String componentId, String streamId);
+ /**
+ * This grouping specifies that you don't care how the stream is grouped.
+ * @param componentId
+ * @return
+ */
public T noneGrouping(String componentId);
+
+ /**
+ * This grouping specifies that you don't care how the stream is grouped.
+ * @param componentId
+ * @param streamId
+ * @return
+ */
public T noneGrouping(String componentId, String streamId);
+ /**
+ * The stream is replicated across all the bolt's tasks. Use this grouping with care.
+ * @param componentId
+ * @return
+ */
public T allGrouping(String componentId);
+
+ /**
+ * The stream is replicated across all the bolt's tasks. Use this grouping with care.
+ * @param componentId
+ * @param streamId
+ * @return
+ */
public T allGrouping(String componentId, String streamId);
+ /**
+ * A stream grouped this way means that the producer of the tuple decides
+ * which task of the consumer will receive this tuple.
+ * @param componentId
+ * @return
+ */
public T directGrouping(String componentId);
+
+ /**
+ * A stream grouped this way means that the producer of the tuple decides
+ * which task of the consumer will receive this tuple.
+ * @param componentId
+ * @param streamId
+ * @return
+ */
public T directGrouping(String componentId, String streamId);
+ /**
+ * Tuples are passed to two hashing functions and each target task is
+ * decided based on the comparison of the state of candidate nodes.
+ * @see https://melmeric.files.wordpress.com/2014/11/the-power-of-both-choices-practical-load-balancing-for-distributed-stream-processing-engines.pdf
+ * @param componentId
+ * @param fields
+ * @return
+ */
public T partialKeyGrouping(String componentId, Fields fields);
+
+ /**
+ * Tuples are passed to two hashing functions and each target task is
+ * decided based on the comparison of the state of candidate nodes.
+ * @see https://melmeric.files.wordpress.com/2014/11/the-power-of-both-choices-practical-load-balancing-for-distributed-stream-processing-engines.pdf
+ * @param componentId
+ * @param streamId
+ * @param fields
+ * @return
+ */
public T partialKeyGrouping(String componentId, String streamId, Fields fields);
+ /**
+ * A custom stream grouping by implementing the CustomStreamGrouping interface.
+ * @param componentId
+ * @param grouping
+ * @return
+ */
public T customGrouping(String componentId, CustomStreamGrouping grouping);
+
+ /**
+ * A custom stream grouping by implementing the CustomStreamGrouping interface.
+ * @param componentId
+ * @param streamId
+ * @param grouping
+ * @return
+ */
public T customGrouping(String componentId, String streamId, CustomStreamGrouping grouping);
public T grouping(GlobalStreamId id, Grouping grouping);
[3/3] storm git commit: Added STORM-663 to Changelog
Posted by bo...@apache.org.
Added STORM-663 to Changelog
Project: http://git-wip-us.apache.org/repos/asf/storm/repo
Commit: http://git-wip-us.apache.org/repos/asf/storm/commit/3113ae1e
Tree: http://git-wip-us.apache.org/repos/asf/storm/tree/3113ae1e
Diff: http://git-wip-us.apache.org/repos/asf/storm/diff/3113ae1e
Branch: refs/heads/master
Commit: 3113ae1ec5a95c9159b203ff016f133e7d2a8e87
Parents: abca012
Author: Robert (Bobby) Evans <ev...@yahoo-inc.com>
Authored: Wed Mar 11 15:27:54 2015 -0500
Committer: Robert (Bobby) Evans <ev...@yahoo-inc.com>
Committed: Wed Mar 11 15:27:54 2015 -0500
----------------------------------------------------------------------
CHANGELOG.md | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/storm/blob/3113ae1e/CHANGELOG.md
----------------------------------------------------------------------
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 53ce8f2..0797c83 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -70,7 +70,8 @@
* STORM-554: the type of first param "topology" should be ^StormTopology not ^TopologyContext
* STORM-469: Storm UI Last Error Detail Insufficient for debugging
* STORM-656: Document "external" modules and "Committer Sponsors"
- * STORM-657:make the shutdown-worker sleep time before kill -9 configurable
+ * STORM-657: make the shutdown-worker sleep time before kill -9 configurable
+ * STORM-663: Create javadocs for BoltDeclarer
## 0.9.3-rc2
* STORM-558: change "swap!" to "reset!" to fix assignment-versions in supervisor
[2/3] storm git commit: Merge branch 'javadoc-for-grouping' of
https://github.com/Lewuathe/storm into STORM-663
Posted by bo...@apache.org.
Merge branch 'javadoc-for-grouping' of https://github.com/Lewuathe/storm into STORM-663
STORM-663: Create javadocs for BoltDeclarer
Project: http://git-wip-us.apache.org/repos/asf/storm/repo
Commit: http://git-wip-us.apache.org/repos/asf/storm/commit/abca012e
Tree: http://git-wip-us.apache.org/repos/asf/storm/tree/abca012e
Diff: http://git-wip-us.apache.org/repos/asf/storm/diff/abca012e
Branch: refs/heads/master
Commit: abca012e6fca2a49cff15f69a11cfd4c48e42da6
Parents: 3a3b7ce 288cc32
Author: Robert (Bobby) Evans <ev...@yahoo-inc.com>
Authored: Wed Mar 11 15:18:45 2015 -0500
Committer: Robert (Bobby) Evans <ev...@yahoo-inc.com>
Committed: Wed Mar 11 15:18:45 2015 -0500
----------------------------------------------------------------------
.../backtype/storm/topology/BoltDeclarer.java | 4 +
.../backtype/storm/topology/InputDeclarer.java | 128 +++++++++++++++++++
2 files changed, 132 insertions(+)
----------------------------------------------------------------------