spiritsx opened a new issue #2338:
URL: https://github.com/apache/rocketmq/issues/2338


   The method 'commit0' of class 'MappedFile' have a parameter 
'commitLeastPages',but it never used from version 4.5.1(we used) to 4.7.1(the 
latest)。
   I guess the paramter is used for judge whether to commit that depends on the 
result 'writePos - this.committedPosition.get()',maybe it looks like ‘writePos 
- this.committedPosition.get() > commitLeastPages ’。Now the code is 'writePos - 
this.committedPosition.get() > 0'。
   By the way,I think the local variable lastCommittedPosition can replace 
'this.committedPosition.get()' In the above inequality。
   Do you think so?
   
![issue](https://user-images.githubusercontent.com/30772323/95434824-4f8e7000-0984-11eb-9507-800689e1f637.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:
[email protected]


Reply via email to