You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@rocketmq.apache.org by GitBox <gi...@apache.org> on 2021/06/24 01:38:20 UTC

[GitHub] [rocketmq] AshleyLiuuuuu opened a new issue #3062: Why is the consume offset become less when the timestamp set to “now”?(MQAdmin)

AshleyLiuuuuu opened a new issue #3062:
URL: https://github.com/apache/rocketmq/issues/3062


   when I'm trying to use resetOffsetByTime command from mqadmin,if I set to now,seems like the rollback offsets returned by the console will always less then the broker offset,why?
   
   ![image](https://user-images.githubusercontent.com/44564641/123189123-d615be00-d4cf-11eb-8ef2-d6da9ca9068e.png)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [rocketmq] panzhi33 edited a comment on issue #3062: Why is the consume offset become less when the timestamp set to “now”?(MQAdmin)

Posted by GitBox <gi...@apache.org>.
panzhi33 edited a comment on issue #3062:
URL: https://github.com/apache/rocketmq/issues/3062#issuecomment-883113737


   https://github.com/apache/rocketmq/issues/2661  you can see this issue


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@rocketmq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [rocketmq] zhaohai1299002788 edited a comment on issue #3062: Why is the consume offset become less when the timestamp set to “now”?(MQAdmin)

Posted by GitBox <gi...@apache.org>.
zhaohai1299002788 edited a comment on issue #3062:
URL: https://github.com/apache/rocketmq/issues/3062#issuecomment-881226318


   First of all, 4.3.0 uses this command resetOffsetByTime, which is indeed the offset of the rollback. And the actual command in the above picture is this resetOffsetByTimeOld, this command is not supported in 4.3.0, and the parameters of the above picture cannot be run with this command, so the author of the above picture changed the source code and ran out.
   ![image](https://user-images.githubusercontent.com/33314633/125906691-8893b628-15d1-406a-8426-b0d555f3d1af.png)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@rocketmq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [rocketmq] panzhi33 edited a comment on issue #3062: Why is the consume offset become less when the timestamp set to “now”?(MQAdmin)

Posted by GitBox <gi...@apache.org>.
panzhi33 edited a comment on issue #3062:
URL: https://github.com/apache/rocketmq/issues/3062#issuecomment-883113737


   https://github.com/apache/rocketmq/issues/2661  you can see this issue


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@rocketmq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [rocketmq] AshleyLiuuuuu commented on issue #3062: Why is the consume offset become less when the timestamp set to “now”?(MQAdmin)

Posted by GitBox <gi...@apache.org>.
AshleyLiuuuuu commented on issue #3062:
URL: https://github.com/apache/rocketmq/issues/3062#issuecomment-881288995


   > First of all, 4.3.0 uses this command resetOffsetByTime, which is indeed the offset of the rollback. And the actual command in the above picture is this resetOffsetByTimeOld, this command is not supported in 4.3.0, and the parameters of the above picture cannot be run with this command, so the author of the above picture changed the source code and ran out.
   > ![image](https://user-images.githubusercontent.com/33314633/125906691-8893b628-15d1-406a-8426-b0d555f3d1af.png)
   
   Hi
   In fact I don't quite understand what you mean, but I found that last year, someone has already noticed this bug, and if you look carefully at the source code will know that either resetOffsetByTime or resetOffsetByTimeOld, the core method to get the specified timestamp offset is always method getOffsetInQueueByTime, and this method I debugged, the timestampOffet will always be smaller than the actual correct consumption offset of 1 unit, so I think it's nothing to do with the version or the commands we use.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@rocketmq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [rocketmq] AshleyLiuuuuu commented on issue #3062: Why is the consume offset become less when the timestamp set to “now”?(MQAdmin)

Posted by GitBox <gi...@apache.org>.
AshleyLiuuuuu commented on issue #3062:
URL: https://github.com/apache/rocketmq/issues/3062#issuecomment-883247637


   > #2661 you can see this issue
   
   
   
   > #2661 you can see this issue
   
   Thanks for the heads-up.
   But does this meet the exact business need really?  Why not just set the timestamp to -1 when users need to reset to "now"?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@rocketmq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [rocketmq] panzhi33 commented on issue #3062: Why is the consume offset become less when the timestamp set to “now”?(MQAdmin)

Posted by GitBox <gi...@apache.org>.
panzhi33 commented on issue #3062:
URL: https://github.com/apache/rocketmq/issues/3062#issuecomment-883113737


   org.apache.rocketmq.store.ConsumeQueue#getOffsetInQueueByTime 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@rocketmq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [rocketmq] panzhi33 commented on issue #3062: Why is the consume offset become less when the timestamp set to “now”?(MQAdmin)

Posted by GitBox <gi...@apache.org>.
panzhi33 commented on issue #3062:
URL: https://github.com/apache/rocketmq/issues/3062#issuecomment-883113737


   org.apache.rocketmq.store.ConsumeQueue#getOffsetInQueueByTime 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@rocketmq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [rocketmq] panzhi33 edited a comment on issue #3062: Why is the consume offset become less when the timestamp set to “now”?(MQAdmin)

Posted by GitBox <gi...@apache.org>.
panzhi33 edited a comment on issue #3062:
URL: https://github.com/apache/rocketmq/issues/3062#issuecomment-883113737


   https://github.com/apache/rocketmq/issues/2661  you can see this issue


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@rocketmq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [rocketmq] zhaohai1299002788 commented on issue #3062: Why is the consume offset become less when the timestamp set to “now”?(MQAdmin)

Posted by GitBox <gi...@apache.org>.
zhaohai1299002788 commented on issue #3062:
URL: https://github.com/apache/rocketmq/issues/3062#issuecomment-881226318


   首先,4.3.0的用的是这个命令resetOffsetByTime,跑出来确实是回滚的偏移量。而上图中的实际命令是这个resetOffsetByTimeOld,这个命令在4.3.0里面没有支持,而且用这个命令跟上面图片的参数是跑不出来的,所以上图作者改了源码才跑出来的。


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@rocketmq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [rocketmq] panzhi33 commented on issue #3062: Why is the consume offset become less when the timestamp set to “now”?(MQAdmin)

Posted by GitBox <gi...@apache.org>.
panzhi33 commented on issue #3062:
URL: https://github.com/apache/rocketmq/issues/3062#issuecomment-883113737


   org.apache.rocketmq.store.ConsumeQueue#getOffsetInQueueByTime 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@rocketmq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [rocketmq] AshleyLiuuuuu commented on issue #3062: Why is the consume offset become less when the timestamp set to “now”?(MQAdmin)

Posted by GitBox <gi...@apache.org>.
AshleyLiuuuuu commented on issue #3062:
URL: https://github.com/apache/rocketmq/issues/3062#issuecomment-868106170


   sos


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [rocketmq] AshleyLiuuuuu edited a comment on issue #3062: Why is the consume offset become less when the timestamp set to “now”?(MQAdmin)

Posted by GitBox <gi...@apache.org>.
AshleyLiuuuuu edited a comment on issue #3062:
URL: https://github.com/apache/rocketmq/issues/3062#issuecomment-883247637


   > #2661 you can see this issue
   
   Thanks for the heads-up.
   But does this meet the exact business need really?  Why not just set the timestamp to -1 when users need to reset to "now"?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@rocketmq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [rocketmq] AshleyLiuuuuu edited a comment on issue #3062: Why is the consume offset become less when the timestamp set to “now”?(MQAdmin)

Posted by GitBox <gi...@apache.org>.
AshleyLiuuuuu edited a comment on issue #3062:
URL: https://github.com/apache/rocketmq/issues/3062#issuecomment-883247637


   > #2661 you can see this issue
   
   Thanks for the heads-up.
   But does this meet the exact business need really?  Why not just set the timestamp to -1 when users need to reset to "now"?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@rocketmq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [rocketmq] AshleyLiuuuuu commented on issue #3062: Why is the consume offset become less when the timestamp set to “now”?(MQAdmin)

Posted by GitBox <gi...@apache.org>.
AshleyLiuuuuu commented on issue #3062:
URL: https://github.com/apache/rocketmq/issues/3062#issuecomment-883247637


   > #2661 you can see this issue
   
   
   
   > #2661 you can see this issue
   
   Thanks for the heads-up.
   But does this meet the exact business need really?  Why not just set the timestamp to -1 when users need to reset to "now"?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@rocketmq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [rocketmq] zhaohai1299002788 commented on issue #3062: Why is the consume offset become less when the timestamp set to “now”?(MQAdmin)

Posted by GitBox <gi...@apache.org>.
zhaohai1299002788 commented on issue #3062:
URL: https://github.com/apache/rocketmq/issues/3062#issuecomment-881229959


   ![image](https://user-images.githubusercontent.com/33314633/125906910-00434460-6025-4217-a1c7-4949155b630d.png)
   ![image](https://user-images.githubusercontent.com/33314633/125907049-c6375a93-06b4-4067-8fac-37d645161e2f.png)
   The code will update the offset through comparison. In fact, there is no problem. If there is any ambiguity about this, you can use the resetOffsetByTime command instead of the resetOffsetByTimeOld.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@rocketmq.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org