You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@flume.apache.org by "jayadeepj (JIRA)" <ji...@apache.org> on 2016/07/06 00:31:10 UTC

[jira] [Created] (FLUME-2946) AtomicIncrement List Null CHeck

jayadeepj created FLUME-2946:
--------------------------------

             Summary: AtomicIncrement List Null CHeck
                 Key: FLUME-2946
                 URL: https://issues.apache.org/jira/browse/FLUME-2946
             Project: Flume
          Issue Type: Bug
          Components: Sinks+Sources
    Affects Versions: v1.6.0
            Reporter: jayadeepj
            Priority: Minor


If I use custom serializer implementing org.apache.flume.sink.hbase.AsyncHbaseEventSerializer; , without any AtomicIncrements i.e  getIncrements() returning null, I get the below exception.

2016-07-06 10:21:34,068 ERROR org.apache.flume.SinkRunner: Unable to deliver event. Exception follows.
java.lang.NullPointerException
	at org.apache.flume.sink.hbase.AsyncHBaseSink.process(AsyncHBaseSink.java:227)
	at org.apache.flume.sink.DefaultSinkProcessor.process(DefaultSinkProcessor.java:68)
	at org.apache.flume.SinkRunner$PollingRunner.run(SinkRunner.java:147)
	at java.lang.Thread.run(Thread.java:745)


I guess since Atomic Increments are optional, it should be null checked in AsyncHBaseSink.java between

“  List<AtomicIncrementRequest> increments = serializer.getIncrements();
…..
callbacksExpected.addAndGet(increments.size());”

Custom serializers shouldn’t have to return empty lists



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)