September 2017
Beginner to intermediate
360 pages
8h 13m
English
This is used to debug the tuples flowing between the operations. The following is the example using the previous functions:
topology.newStream("spout1", spout).flatMap(new SplitMapFunction()).map(new UpperCase()).peek( new Consumer() { @Override public void accept(TridentTuple tuple) { System.out.print("["); for (int index = 0; index < tuple.size(); index++) { System.out.print(tuple.get(index)); if (index < (tuple.size() - 1)) System.out.print(","); } System.out.println("]"); }});
Read now
Unlock full access