[ 
https://issues.apache.org/jira/browse/HDDS-1348?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16813042#comment-16813042
 ] 

Jitendra Nath Pandey commented on HDDS-1348:
--------------------------------------------

A few comments:
 # Why don't we always call adjustBuffers on 
{{xceiverClient.getReplicatedMinCommitIndex()}}? Isn't 
replicated-min-commit-index is the source of truth in all cases.
 # I think {{totalAckDataLength}} should be updated as soon as we get an ack, 
instead of adjustBuffer. We are coupling the buffer-management with tracking of 
acks.
 # {{watchOnCommitIndex(boolean first)}}: It would be better to have two 
different functions, one for buffer full case, and another for flush. A boolean 
flag can be confusing for example, suppose when we call flush, buffer is full 
as well, so it becomes tricky to understand code.
 # Please add unit tests only for CommitWatcher class. The test should mockĀ 
xceiverClient, and test buffers are appropriately released, for exception as 
well as non-exception cases.
 # Let's make \{{CommitWatcher#getCommitIndex2flushedDataMap}} visible for 
testing.

> Refactor BlockOutpuStream Class
> -------------------------------
>
>                 Key: HDDS-1348
>                 URL: https://issues.apache.org/jira/browse/HDDS-1348
>             Project: Hadoop Distributed Data Store
>          Issue Type: Improvement
>          Components: Ozone Client
>            Reporter: Shashikant Banerjee
>            Assignee: Shashikant Banerjee
>            Priority: Major
>             Fix For: 0.5.0
>
>         Attachments: HDDS-1348.000.patch
>
>
> BlockOutputStream contains functionalities for handling write, flush and 
> close as well as tracking commitIndexes . The idea is to separate all 
> commitIndex tracking and management code outside of BlockOutputStream class



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to