On May 30, 2013, at 21:25 , Aboubakr Benabbas wrote:


I would like to know how can one implement PEs in a way, one PE outputs events that are inputs for other PEs

PEs are connected through streams, and events flow from PE to PE through those streams. So when creating the PE graph, just make sure you have (down)streams created in PE prototypes and that you use them for building the PE graph. 

For instance, in the twitter counter example, the TopicExtractor PE can set a down stream: https://github.com/apache/incubator-s4/blob/dev/test-apps/twitter-counter/src/main/java/org/apache/s4/example/twitter/TopicExtractorPE.java#L48

and the set operation is performed when building the app graph: https://github.com/apache/incubator-s4/blob/dev/test-apps/twitter-counter/src/main/java/org/apache/s4/example/twitter/TwitterCounterApp.java#L79

Hope this helps,