Details
Description
We use ADLS to store customer data and to access the data from our containers HttpFS Server-Client is used. HttpFS functions like GETFILESTATUS, RENAME expect absolute 'path' of the file(s) as the argument. But when the request is received at the server from HttpFs Client, the server is forwarding only the relative path rather than absolute path to ADLS. This is breaking the logic for GETFILESTATUS, RENAME functions.
Steps to reproduce GETFILESTATUS Command Bug:
Run the following command from the client:
Example 1:
hadoop fs –ls adl_scheme://account/folderA/folderB/
Server logs show only the relative path "folderA/folderB/" is forwarded to ADLS.
Example 2:
hadoop fs –ls adl_scheme://account/folderX/folderY/SampleFile
Server logs show only the relative path "folderX/folderY/SampleFile" is forwarded to ADLS.
Fix:
Prepend the ADLS scheme and account name to the path. So the path in example 1 and example 2 would look like this 'adl_scheme://account/folderA/folderB/' and 'adl_scheme://account/folderX/folderY/SampleFile' respectively.
Steps to reproduce RENAME Command Bug:
Run the following command from the client:
Example 1:
Hadoop fs –mv /folderA/oldFileName /folderA/newFileName
Server logs show only the relative old file path "folderA/oldFileName" and new File path "adl_scheme://account/folderA/newFileName" is forwarded to ADLS.
Fix:
Prepend the ADLS scheme and account name to the old file name path.