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

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

                Author: ASF GitHub Bot
            Created on: 11/Dec/20 12:08
            Start Date: 11/Dec/20 12:08
    Worklog Time Spent: 10m 
      Work Description: steveloughran commented on pull request #2530:
URL: https://github.com/apache/hadoop/pull/2530#issuecomment-743157050


   This is how the "-getfattr" command looks like against a non-magic-marker 
file
   
   ```
    bin/hadoop fs -getfattr -d 
s3a://stevel-london/cloud-integration/DELAY_LISTING_ME/S3ACommitBulkDataSuite/bulkdata/output/landsat/parquet/parted-1/year=2016/month=10/part-00000-8b00c5f2-cd1f-4741-9278-1a2f0af3a9a9.c000.snappy.parquet
   2020-12-11 12:06:19,361 [main] INFO  s3a.S3AFileSystem 
(S3Guard.java:logS3GuardDisabled(1135)) - S3Guard is disabled on this bucket: 
stevel-london
   2020-12-11 12:06:19,366 [main] INFO  impl.DirectoryPolicyImpl 
(DirectoryPolicyImpl.java:getDirectoryPolicy(189)) - Directory markers will be 
kept
   # file: 
s3a://stevel-london/cloud-integration/DELAY_LISTING_ME/S3ACommitBulkDataSuite/bulkdata/output/landsat/parquet/parted-1/year=2016/month=10/part-00000-8b00c5f2-cd1f-4741-9278-1a2f0af3a9a9.c000.snappy.parquet
   header.Content-Disposition
   header.Content-Encoding
   header.Content-Language
   header.Content-Length="92337"
   header.Content-MD5
   header.Content-Range
   header.Content-Type="application/octet-stream"
   header.ETag="b445e3e08b71650e906789a0f5a80c7b-1"
   header.Last-Modified="Thu Dec 10 15:10:12 GMT 2020"
   ```


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

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


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

    Worklog Id:     (was: 523166)
    Time Spent: 2h  (was: 1h 50m)

> Magic committer files don't have the count of bytes written collected by spark
> ------------------------------------------------------------------------------
>
>                 Key: HADOOP-17414
>                 URL: https://issues.apache.org/jira/browse/HADOOP-17414
>             Project: Hadoop Common
>          Issue Type: Sub-task
>          Components: fs/s3
>    Affects Versions: 3.2.0
>            Reporter: Steve Loughran
>            Assignee: Steve Loughran
>            Priority: Major
>              Labels: pull-request-available
>          Time Spent: 2h
>  Remaining Estimate: 0h
>
> The spark statistics tracking doesn't correctly assess the size of the 
> uploaded files as it only calls getFileStatus on the zero byte objects -not 
> the yet-to-manifest files. Which, given they don't exist yet, isn't easy to 
> do.
> Solution: 
> * Add getXAttr and listXAttr API calls to S3AFileSystem
> * Return all S3 object headers as XAttr attributes prefixed "header." That's 
> custom and standard (e.g header.Content-Length).
> The setXAttr call isn't implemented, so for correctness the FS doesn't
> declare its support for the API in hasPathCapability().
> The magic commit file write sets the custom header 
> set the length of the data final data in the header
> x-hadoop-s3a-magic-data-length in the marker file.
> A matching patch in Spark will look for the XAttr
> "header.x-hadoop-s3a-magic-data-length" when the file
> being probed for output data is zero byte long. 
> As a result, the job tracking statistics will report the
> bytes written but yet to be manifest.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

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

Reply via email to