[ 
https://issues.apache.org/jira/browse/HADOOP-18330?focusedWorklogId=793330&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-793330
 ]

ASF GitHub Bot logged work on HADOOP-18330:
-------------------------------------------

                Author: ASF GitHub Bot
            Created on: 20/Jul/22 16:14
            Start Date: 20/Jul/22 16:14
    Worklog Time Spent: 10m 
      Work Description: steveloughran commented on code in PR #4572:
URL: https://github.com/apache/hadoop/pull/4572#discussion_r925806836


##########
hadoop-tools/hadoop-aws/src/main/java/org/apache/hadoop/fs/s3a/S3ClientFactory.java:
##########
@@ -264,5 +270,26 @@ public S3ClientCreationParameters withHeader(
     public Map<String, String> getHeaders() {
       return headers;
     }
+
+    /**
+     * Get the full s3 path.
+     * added in HADOOP-18330
+     * @return path URI
+     */
+    public URI getPath() {

Review Comment:
   can you name the getter/setter to pathUri for consistency?





Issue Time Tracking
-------------------

    Worklog Id:     (was: 793330)
    Time Spent: 3.5h  (was: 3h 20m)

> S3AFileSystem removes Path when calling createS3Client
> ------------------------------------------------------
>
>                 Key: HADOOP-18330
>                 URL: https://issues.apache.org/jira/browse/HADOOP-18330
>             Project: Hadoop Common
>          Issue Type: Bug
>          Components: fs/s3
>    Affects Versions: 3.3.0, 3.3.1, 3.3.2, 3.3.3
>            Reporter: Ashutosh Pant
>            Assignee: Ashutosh Pant
>            Priority: Minor
>              Labels: pull-request-available
>          Time Spent: 3.5h
>  Remaining Estimate: 0h
>
> when using hadoop and spark to read/write data from an s3 bucket like -> 
> s3a://bucket/path and using a custom Credentials Provider, the path is 
> removed from the s3a URI and the credentials provider fails because the full 
> path is gone.
> In Spark 3.2,
> It was invoked as -> s3 = ReflectionUtils.newInstance(s3ClientFactoryClass, 
> conf)
> .createS3Client(name, bucket, credentials); 
> But In spark 3.3.3
> It is invoked as s3 = ReflectionUtils.newInstance(s3ClientFactoryClass, 
> conf).createS3Client(getUri(), parameters);
> the getUri() removes the path from the s3a URI



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