I used 2 different consumers to consume data from the same topic. I expected the 2 consumers to return the same result. But I found that there were messages which was caught by the first consumer but failed to be caught by second consumer. I had no idea what caused this. Can someone told me what I can do to guarantee that no message should be lost in consumption?
First I tried to set a time gap which was 1 hour. Then I used 2 different consumers to get messages which were created in an hour.I compared the number of messages caught by 2 consumers, they are different. I tried setting different time gap but the outcome from different consumers were still different.
It's the MessageModel, NOT message loss. you can try MessageModel.BROADCASTING
MessageModel.CLUSTERING. image show here
MessageModel.BROADCASTING image show here
code demo