HADOOP-19854: ABFS. Namespace Detection for FNS Accounts with Soft Delete Enabled#8410
HADOOP-19854: ABFS. Namespace Detection for FNS Accounts with Soft Delete Enabled#8410manika137 wants to merge 3 commits intoapache:trunkfrom
Conversation
Test Results============================================================
|
|
🎊 +1 overall
This message was automatically generated. |
anujmodi2021
left a comment
There was a problem hiding this comment.
Need test imprvements
| /* | ||
| * HTTP_CONFLICT with soft delete not supported error indicates a FNS account. | ||
| * This occurs when: | ||
| * 1. FNS-Blob endpoint is used (used with DFS endpoint for getAcl call) |
There was a problem hiding this comment.
nit: used coming twice
| * This occurs when: | ||
| * 1. FNS-Blob endpoint is used (used with DFS endpoint for getAcl call) | ||
| * 2. FNS-DFS endpoint is used (later internally converted to Blob) | ||
| * For both cases, namespace should be disabled. No need to throw exception. |
There was a problem hiding this comment.
Also add a line that for both cases ultimately Blob endpoint will be used so this error is irrelevant as it comes only on DFS Endpoint
| statusCode, null, errorMsg, null); | ||
| doThrow(ex).when(mockClient).getAclStatus(anyString(), any(TracingContext.class)); | ||
|
|
||
| if (isExceptionExpected) { |
There was a problem hiding this comment.
Need some more testing no just mock.
I understand that we can't control account's soft-delete feature but let's run all the integration tests on an account where soft-delete is enabled if not already done.
And in integration tests we can assert that if error code returned by server can either be Bad request of htp conflict.
There was a problem hiding this comment.
Sure, will add integration tests
I have run the test suite with account's soft-delete enabled as well. Apart from the list failing (with startfrom param) that we have a fix coming up for- we're good
|
🎊 +1 overall
This message was automatically generated. |
|
🎊 +1 overall
This message was automatically generated. |
Description of PR
JIRA: https://issues.apache.org/jira/browse/HADOOP-19854
If fs.azure.account.hns.enabled is not configured, ABFS driver issues a getAcl call using the DFS endpoint to detect the account type (HNS or FNS)
For FNS Blob accounts with Soft Delete enabled, this behavior leads to failures because the DFS endpoint used does not support Soft Delete semantics.
Temporary fix is to explicitly set the configuration: fs.azure.account.hns.enabled so the redundant DFS-based detection is bypassed and the issue does not occur.
Raising PR for the code fix
How was this patch tested?
Test suite was run. Adding the results in the comments below