HDDS-9323. Apply expiry of excluded datanodes to writing Ratis keys#5530
HDDS-9323. Apply expiry of excluded datanodes to writing Ratis keys#5530adoroszlai merged 11 commits intoapache:masterfrom
Conversation
sumitagrawl
left a comment
There was a problem hiding this comment.
@DaveTeng0 Thanks for working over this, have minor comments, please check
hadoop-ozone/client/src/main/java/org/apache/hadoop/ozone/client/io/KeyOutputStream.java
Outdated
Show resolved
Hide resolved
hadoop-ozone/client/src/main/java/org/apache/hadoop/ozone/client/io/KeyOutputStream.java
Outdated
Show resolved
Hide resolved
hadoop-ozone/client/src/main/java/org/apache/hadoop/ozone/client/io/KeyOutputStream.java
Outdated
Show resolved
Hide resolved
hadoop-hdds/client/src/main/java/org/apache/hadoop/hdds/scm/storage/BlockOutputStream.java
Outdated
Show resolved
Hide resolved
…ethod in BlockOutputStreamEntryPool to use constructor of ExcludeList with clock
sumitagrawl
left a comment
There was a problem hiding this comment.
@DaveTeng0 Give few review comments
hadoop-hdds/client/src/main/java/org/apache/hadoop/hdds/scm/OzoneClientConfig.java
Outdated
Show resolved
Hide resolved
hadoop-ozone/client/src/test/java/org/apache/hadoop/ozone/client/io/TestKeyOutputStream.java
Outdated
Show resolved
Hide resolved
hadoop-ozone/client/src/test/java/org/apache/hadoop/ozone/client/io/TestKeyOutputStream.java
Outdated
Show resolved
Hide resolved
|
@DaveTeng0 please check integration test failures: https://github.com/DaveTeng0/ozone/actions/runs/6818659142/job/18545006173 |
yup thanks attila! These two tests failure are on my radar! |
hadoop-ozone/client/src/test/java/org/apache/hadoop/ozone/client/io/TestKeyOutputStream.java
Outdated
Show resolved
Hide resolved
… exclude list on client side
|
note: there are unit test for ExcludeList.java already in https://github.com/apache/ozone/blob/master/hadoop-hdds/common/src/test/java/org/apache/hadoop/hdds/scm/container/common/helpers/TestExcludeList.java#L32 |
adoroszlai
left a comment
There was a problem hiding this comment.
I think we should apply the same in streaming write:
sumitagrawl
left a comment
There was a problem hiding this comment.
@DaveTeng0 Have minor comment
| ExcludeList createExcludeList() { | ||
| return new ExcludeList(); | ||
| return new ExcludeList(getConfig().getExcludeNodesExpiryTime(), | ||
| Clock.system(ZoneOffset.UTC)); |
There was a problem hiding this comment.
new use createExcludeList() for constructor BlockOutputStreamEntryPool() at line 140 as used.
https://github.com/apache/ozone/pull/5530/files#diff-db8e4914806b73e8ec37c15ffd146fc70bd1fcba631df9a314c7389af64a895dL140
oh yes you're right! updated. |
|
@DaveTeng0 please merge |
oh sure! working on it! |
adoroszlai
left a comment
There was a problem hiding this comment.
Thanks @DaveTeng0 for updating the patch, LGTM.
|
Thanks @DaveTeng0 for the patch, @sumitagrawl for the review. |
…Ratis keys (apache#5530) (cherry picked from commit cddc571) Change-Id: I4a2e1d12c1bfb6593a43850869a9b24dabcb1d2a
What changes were proposed in this pull request?
Currently it is possible that a long lived client can add most or all nodes of a small cluster to its exclude list, and further writes using that client instance will fail. This PR add a timeout for RATIS key to remove datanodes from the exclude list so that they can be retried later.
(For EC key, this mechanism exists and is configured to 10 minutes by default.)
This improvement is especially relevant for S3 gateway, which uses a persistent Ozone client to connect to the cluster.
And there is another part of improvement that allows the write to fall back to datanodes in the exclude list if that is all available. This would be implemented as a retry from the client based on the server's initial error response.
This part of work is separated into another PR: #5514
What is the link to the Apache JIRA
https://issues.apache.org/jira/browse/HDDS-9323
How was this patch tested?
unit test