Apache Spark Kinesis Sample not working

前端 未结 2 1771
慢半拍i
慢半拍i 2020-12-18 16:29

I am trying to run the JavaKinesisWordCountASL example.

The example seem to connect to my Kinesis Stream and gets data from the stream (as shown in the log below).

2条回答
  •  难免孤独
    2020-12-18 16:57

    This might have something to do with how many worker thread you got. I had the same problem when I ran the app with --master local[2]. I spent numerous hours searching for an answer and found nothing. Just out of curiosity, I changed to --master local[4] and it worked. I do not know the root cause. Maybe somebody more familiar with Spark can enlighten us.

    Note: in my case, my Kinesis stream had two shards. So the app created two input streams, one for each shard.

提交回复
热议问题