steveloughran opened a new pull request #3442:
URL: https://github.com/apache/hadoop/pull/3442


   
   This PR ensures that
   
   * `FileSystem.getCanonicalServiceName()` is *never* used to build an abfs 
service name from the IPaddr of the storage account's endpoint.
   * Instead, if DTs are enabled, the `AbfsDelegationTokenManager` gets it from 
the DT plugin if it implements `getCanonicalServiceName()` & returns a non-null 
value, else derives it from the FS URI.
   * And if DTs are disabled: returns null.
   
   The fallback calculation of the Canonical Service Name is abfs:// + 
fsURI.getHost() + "/"
   
   1. schema is always abfs, even for abfss stores
   1. the container is stripped from the service name.
   1. so all abfs containers for the same service a/c will have the same 
Canonical Service Name
   1. share a single DT in job submission
   1. *and*: if a DT is issued for one of the containers in job submission, all 
other containers for the same storage a/c will use that DT
   1. Even if the caller didn't explicitly name it.
   
   That is consistent with using the storage a/c's endpoint IPAddr to identify 
the storage account.
   
   Today, `abfs://[email protected]/` and
    `abfs://[email protected]/` will both have their CSN 
map to the same endpoint hostname *if the DT plugin doesn't return a schema*
   
   If the DT plugin returns a schema -which it should, this is all moot. This 
is a fallback if they don't.
   
   Tests updated to match new behavior.
   
   ### How was this patch tested?
   
   azure cardiff
   
   ### For code changes:
   
   - [X] Does the title or this PR starts with the corresponding JIRA issue id 
(e.g. 'HADOOP-17799. Your PR title ...')?
   - [X] Object storage: have the integration tests been executed and the 
endpoint declared according to the connector-specific documentation?
   - [ ] If adding new dependencies to the code, are these dependencies 
licensed in a way that is compatible for inclusion under [ASF 
2.0](http://www.apache.org/legal/resolved.html#category-a)?
   - [ ] If applicable, have you updated the `LICENSE`, `LICENSE-binary`, 
`NOTICE-binary` files?
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]



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

Reply via email to