mynameborat commented on a change in pull request #984: Samza 2116: Making sink, sendTo(table), sendTo(stream) non-terminal URL: https://github.com/apache/samza/pull/984#discussion_r272007095
########## File path: samza-api/src/main/java/org/apache/samza/operators/functions/SinkFunction.java ########## @@ -42,6 +42,6 @@ * @param messageCollector the {@link MessageCollector} to send the message * @param taskCoordinator the {@link TaskCoordinator} to request commits or shutdown */ - void apply(M message, MessageCollector messageCollector, TaskCoordinator taskCoordinator); + M apply(M message, MessageCollector messageCollector, TaskCoordinator taskCoordinator); Review comment: +1 It introduces confusion from the perspective of how is this even different from MapFunction? Further, it opens up possibility for applications to return a different message than the input which makes it harder to reason about the semantics of SinkFunction. ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services