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/04/22 07:58:21 UTC

[GitHub] [rocketmq] iamqq23ue edited a comment on pull request #2707: [ISSUE #2706] Fix the problem of returning SEND_OK after flush failed

iamqq23ue edited a comment on pull request #2707:
URL: https://github.com/apache/rocketmq/pull/2707#issuecomment-824596217


   But there is a try catch,code as below:
   catch (Throwable e) {            
        log.error("Error occurred when force data to disk.", e);          
      }
   In my test,I can see the error "Error occurred when force data to disk." in log。But the exception is caught so it does not affect code execution
   
   
   ------------------&nbsp;原始邮件&nbsp;------------------
   发件人:                                                                                                                        "apache/rocketmq"                                                                                    ***@***.***&gt;;
   发送时间:&nbsp;2021年4月22日(星期四) 下午3:00
   ***@***.***&gt;;
   ***@***.***&gt;;"State ***@***.***&gt;;
   主题:&nbsp;Re: [apache/rocketmq] [ISSUE #2706]  Fix the problem of returning SEND_OK after flush failed  (#2707)
   
   
   
   
   
      
   Good catch! But I feel that the change is a bit complicated. When the flushing error occurs, the location flushedPosition does not move and will return to the client FLUSH_DISK_TIMEOUT.
     
   this.flushedPosition.set(value);
    You can see that this line of code will be executed no matter what。So even if an error is reported, the position will change。
     
   You're right. But when an exception is thrown, we can not set  flushedPosition.
    
   —
   You are receiving this because you modified the open/close state.
   Reply to this email directly, view it on GitHub, or unsubscribe.


-- 
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