Hi.

I explored "directGrouping".
I have some questions.
So, based on this  webpage for "Direct grouping" (
http://storm.apache.org/releases/current/Concepts.html), we can use direct
grouping by using  API like *.directGrouping("input executor","streamId");*
After that, we can use "emitDirect".
So, in this case it worked.

However, I am not sure when we can use this approach?
"by keeping track of the output of the emit method in OutputCollector
<http://storm.apache.org/releases/current/javadocs/org/apache/storm/task/OutputCollector.html>
 (which returns the task ids that the tuple was sent to)"?
We can get task ids after emit() method from shuffling or fields grouping.
However, if I use emitDirect() method in a class which declare shuffling or
fields grouping as grouping, it showed an error.
In addition, I cannot use emit() method in a class which declared
directGrouping.

 I think this is related to "Direct groupings can only be declared on
streams that have been declared as direct streams" (
http://storm.apache.org/releases/current/Concepts.html) and
It seemed in code there is "todo" for this ( task.clj 158 line).


Basically, does webpage explain if the streamID is "direct", we can use
emitDirect() in any grouping? Is it right?

One more question, if I want to use one-to-many (not one-to-all)
communication, I use directGrouping and specify destinations in my bolt or
spout code.
Is it right?

Thanks,
Junguk

Reply via email to