[ 
https://issues.apache.org/jira/browse/HDDS-14194?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Ivan Andika resolved HDDS-14194.
--------------------------------
    Resolution: Implemented

> Make streaming write SYNC configurable
> --------------------------------------
>
>                 Key: HDDS-14194
>                 URL: https://issues.apache.org/jira/browse/HDDS-14194
>             Project: Apache Ozone
>          Issue Type: Sub-task
>            Reporter: Ivan Andika
>            Assignee: Ivan Andika
>            Priority: Major
>              Labels: pull-request-available
>
> See BlockDataStreamOutput#needSync, currently SYNC is never used and 
> therefore we might not be sure when the data is actually flushed to the disk 
> (see StreamDataChannelBase#force which will invoke FileChannel#force(false) 
> to flush the data to the underlying storage)
> {code:java}
> private boolean needSync(long position) {
>   if (SYNC_SIZE > 0) {
>     // TODO: or position >= fileLength
>     if (position - syncPosition >= SYNC_SIZE) {
>       syncPosition = position;
>       return true;
>     }
>   }
>   return false;
> } {code}
> We can create a configuration to allow SYNC, which is disabled by default to 
> preserve compatibility.
> We also might want to revisit whether we should make SYNC to be a client-side 
> or server-side. The concern is if a client is misconfigured, it might cause a 
> lot of sync on the DN which will cause higher latencies.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

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

Reply via email to