collector.ack(input); collector.fail(input); collector.reportError(th); collector.ack(input);
collector.ack(input); collector.fail(input); collector.reportError(th); collector.ack(input);
protected void init(TopologyContext context, OutputCollector collector) { this.collector = new AnchoringOutputCollector(collector); this.checkPointInputTaskCount = getCheckpointInputTaskCount(context); }
/** * Forwards the checkpoint tuple downstream. Sub-classes can override * with the logic for handling checkpoint tuple. * * @param checkpointTuple the checkpoint tuple * @param action the action (prepare, commit, rollback or initstate) * @param txid the transaction id. */ protected void handleCheckpoint(Tuple checkpointTuple, Action action, long txid) { collector.emit(CheckpointSpout.CHECKPOINT_STREAM_ID, checkpointTuple, new Values(txid, action)); collector.ack(checkpointTuple); }
protected void init(TopologyContext context, OutputCollector collector) { this.collector = new AnchoringOutputCollector(collector); this.checkPointInputTaskCount = getCheckpointInputTaskCount(context); }
/** * Forwards the checkpoint tuple downstream. Sub-classes can override * with the logic for handling checkpoint tuple. * * @param checkpointTuple the checkpoint tuple * @param action the action (prepare, commit, rollback or initstate) * @param txid the transaction id. */ protected void handleCheckpoint(Tuple checkpointTuple, Action action, long txid) { collector.emit(CheckpointSpout.CHECKPOINT_STREAM_ID, checkpointTuple, new Values(txid, action)); collector.ack(checkpointTuple); }