Search in sources :

Example 1 with LumberjackChannelResponse

use of org.apache.nifi.processors.lumberjack.response.LumberjackChannelResponse in project nifi by apache.

the class ListenLumberjack method respond.

protected void respond(final LumberjackEvent event, final LumberjackResponse lumberjackResponse) {
    final ChannelResponse response = new LumberjackChannelResponse(lumberjackEncoder, lumberjackResponse);
    final ChannelResponder responder = event.getResponder();
    responder.addResponse(response);
    try {
        responder.respond();
    } catch (IOException e) {
        getLogger().error("Error sending response for transaction {} due to {}", new Object[] { event.getSeqNumber(), e.getMessage() }, e);
    }
}
Also used : ChannelResponder(org.apache.nifi.processor.util.listen.response.ChannelResponder) LumberjackChannelResponse(org.apache.nifi.processors.lumberjack.response.LumberjackChannelResponse) ChannelResponse(org.apache.nifi.processor.util.listen.response.ChannelResponse) LumberjackChannelResponse(org.apache.nifi.processors.lumberjack.response.LumberjackChannelResponse) IOException(java.io.IOException)

Aggregations

IOException (java.io.IOException)1 ChannelResponder (org.apache.nifi.processor.util.listen.response.ChannelResponder)1 ChannelResponse (org.apache.nifi.processor.util.listen.response.ChannelResponse)1 LumberjackChannelResponse (org.apache.nifi.processors.lumberjack.response.LumberjackChannelResponse)1