Skip to content

delay message can't be consumed #1869

@yongliangcode

Description

@yongliangcode

BUG REPORT

  1. Please describe the issue you observed:
  • What did you do (The steps to reproduce)?
    In our production environment,producer send delay message,but this message can not be consumed.

Producer code
Message msg = new Message("my_test_topic",
value.getBytes(RemotingHelper.DEFAULT_CHARSET));
msg.setKeys(key);
msg.setDelayTimeLevel(4);
SendResult sendResult = producer.send(msg);

  • What did you expect to see?

This message can be consumed correct.

  • What did you see instead?
    In the storeerror.log there are a lot of error message.
    2020-03-18 16:38:06 WARN ScheduleMessageTimerThread - Offset not matched. Request offset: 509548460, firstOffset: 0, lastOffset: 6000000, mappedFileSize: 6000000, mappedFiles count: 1
    2020-03-18 16:38:06 WARN ScheduleMessageTimerThread - Offset not matched. Request offset: 665682360, firstOffset: 0, lastOffset: 6000000, mappedFileSize: 6000000, mappedFiles count: 1
    2020-03-18 16:38:07 WARN ScheduleMessageTimerThread - Offset not matched. Request offset: 509548460, firstOffset: 0, lastOffset: 6000000, mappedFileSize: 6000000, mappedFiles count: 1
    2020-03-18 16:38:07 WARN ScheduleMessageTimerThread - Offset not matched. Request offset: 665682360, firstOffset: 0, lastOffset: 6000000, mappedFileSize: 6000000, mappedFiles count: 1
    2020-03-18 16:38:07 WARN ScheduleMessageTimerThread - Offset not matched. Request offset: 509548460, firstOffset: 0, lastOffset: 6000000, mappedFileSize: 6000000, mappedFiles count: 1
    2020-03-18 16:38:07 WARN ScheduleMessageTimerThread - Offset not matched. Request offset: 665682360, firstOffset: 0, lastOffset: 6000000, mappedFileSize: 6000000, mappedFiles count: 1
    2020-03-18 16:38:07 WARN ScheduleMessageTimerThread - Offset not matched. Request offset: 509548460, firstOffset: 0, lastOffset: 6000000, mappedFileSize: 6000000, mappedFiles count: 1
    2020-03-18 16:38:07 WARN ScheduleMessageTimerThread - Offset not matched. Request offset: 665682360, firstOffset: 0, lastOffset: 6000000, mappedFileSize: 6000000, mappedFiles count: 1
  1. Please tell us about your environment:
    Our production environment. RocketMQ 4.5.2;But other rocketmq cluster of this version run ok.

  2. Other information (e.g. detailed explanation, logs, related issues, suggestions how to fix, etc):
    After remove file "consumequeue/SCHEDULE_TOPIC_XXXX" and remove "config/delayOffset.json" file, restart the broker, delay message restore, consume correctly.

Reference event review process:
https://mp.weixin.qq.com/s/f27tcOlm0_BTvL8725RPTQ

Metadata

Metadata

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions