Uploaded image for project: 'Kafka'
  1. Kafka
  2. KAFKA-8142

Kafka Streams fails with NPE if record contains null-value in header

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.1.1
    • Fix Version/s: 2.3.0, 2.1.2, 2.2.1
    • Component/s: streams
    • Labels:
      None

      Description

      [2019-03-14 13:14:49,756] ERROR stream-thread [<mask-app-id>-2-1-1f30b4e6-1204-4aa7-9426-a395ab06ad64-StreamThread-2] Failed to process stream task 9_2 due to the following error: (org.apache.kafka.str
      eams.processor.internals.AssignedStreamsTasks)
      java.lang.NullPointerException
      at org.apache.kafka.streams.processor.internals.ProcessorRecordContext.sizeBytes(ProcessorRecordContext.java:93)
      at org.apache.kafka.streams.state.internals.ContextualRecord.sizeBytes(ContextualRecord.java:42)
      at org.apache.kafka.streams.state.internals.LRUCacheEntry.<init>(LRUCacheEntry.java:53)
      at org.apache.kafka.streams.state.internals.CachingWindowStore.put(CachingWindowStore.java:160)
      at org.apache.kafka.streams.state.internals.CachingWindowStore.put(CachingWindowStore.java:36)
      at org.apache.kafka.streams.state.internals.MeteredWindowStore.put(MeteredWindowStore.java:114)
      at org.apache.kafka.streams.kstream.internals.KStreamWindowAggregate$KStreamWindowAggregateProcessor.process(KStreamWindowAggregate.java:124)
      at org.apache.kafka.streams.processor.internals.ProcessorNode.process(ProcessorNode.java:117)
      at org.apache.kafka.streams.processor.internals.ProcessorContextImpl.forward(ProcessorContextImpl.java:146)
      at org.apache.kafka.streams.processor.internals.ProcessorContextImpl.forward(ProcessorContextImpl.java:129)
      at org.apache.kafka.streams.processor.internals.ProcessorContextImpl.forward(ProcessorContextImpl.java:93)
      at org.apache.kafka.streams.processor.internals.SourceNode.process(SourceNode.java:84)
      at org.apache.kafka.streams.processor.internals.StreamTask.process(StreamTask.java:351)
      at org.apache.kafka.streams.processor.internals.AssignedStreamsTasks.process(AssignedStreamsTasks.java:104)
      at org.apache.kafka.streams.processor.internals.TaskManager.process(TaskManager.java:413)
      at org.apache.kafka.streams.processor.internals.StreamThread.runOnce(StreamThread.java:862)
      at org.apache.kafka.streams.processor.internals.StreamThread.runLoop(StreamThread.java:777)
      at org.apache.kafka.streams.processor.internals.StreamThread.run(StreamThread.java:747)

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                mjsax Matthias J. Sax
                Reporter:
                mjsax Matthias J. Sax
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: