[ 
https://issues.apache.org/jira/browse/HADOOP-18945?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17776729#comment-17776729
 ] 

ASF GitHub Bot commented on HADOOP-18945:
-----------------------------------------

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

   
   - Enable async refresh in inner credential provider.
   - Store provider instance in a field; use synchronized() call to handle 
failure and switch from container to EC2 provider.
   - Close inner provider in close();
   - use ErrorTranslation to extract any IOE at base on stack
   - rename maybeExtractNetworkException to maybeExtractIOException (as 
requested in review of third party support)
   - test for error translation going through UncheckedIOException
   - TestIAMInstanceCredentialsProvider to test fallback process
   
   TestIAMInstanceCredentialsProvider is tricky as there are different test 
outcomes
   
   1. In EC2: credentials resolved. Assert comes with a key.
   2. Not in EC2: network error trying to talk to the service. Assert wrapped 
exception is an IOE.
   3. IMDS resolution disabled by env var/sysprop. Expect the message to 
contain the text from the SDK
   
   The test is potentially brittle; there may be followups.
   
   
   ### How was this patch tested?
   
   * Tested with `AWS_EC2_METADATA_DISABLED=true` (my default) and with it 
unset.
   * Not tested in EC2/k8s yet, that will be the success path.
   
   
   ### For code changes:
   
   - [ ] Does the title or this PR starts with the corresponding JIRA issue id 
(e.g. 'HADOOP-17799. Your PR title ...')?
   - [ ] 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?
   
   




> S3A: IAMInstanceCredentialsProvider failing: Failed to load credentials from 
> IMDS
> ---------------------------------------------------------------------------------
>
>                 Key: HADOOP-18945
>                 URL: https://issues.apache.org/jira/browse/HADOOP-18945
>             Project: Hadoop Common
>          Issue Type: Sub-task
>          Components: fs/s3
>    Affects Versions: 7.2.18.0
>            Reporter: Steve Loughran
>            Assignee: Steve Loughran
>            Priority: Blocker
>
> Failures in impala test VMs using iAM for auth
> {code}
> Failed to open file as a parquet file: java.net.SocketTimeoutException: 
> re-open 
> s3a://impala-test-uswest2-1/test-warehouse/test_pre_gregorian_date_parquet_2e80ae30.db/hive2_pre_gregorian.parquet
>  at 84 on 
> s3a://impala-test-uswest2-1/test-warehouse/test_pre_gregorian_date_parquet_2e80ae30.db/hive2_pre_gregorian.parquet:
>  org.apache.hadoop.fs.s3a.auth.NoAwsCredentialsException: +: Failed to load 
> credentials from IMDS
> {code}



--
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