bgaborg commented on a change in pull request #991: HADOOP-16382: clock skew 
can cause S3Guard to think object metadata is out of date
URL: https://github.com/apache/hadoop/pull/991#discussion_r295860982
 
 

 ##########
 File path: 
hadoop-tools/hadoop-aws/src/main/java/org/apache/hadoop/fs/s3a/s3guard/PathMetadata.java
 ##########
 @@ -71,6 +79,8 @@ public PathMetadata(S3AFileStatus fileStatus, Tristate 
isEmptyDir, boolean
     this.fileStatus = fileStatus;
     this.isEmptyDirectory = isEmptyDir;
     this.isDeleted = isDeleted;
+    // modtime is derived from file status
+    setLastUpdated(fileStatus.getModificationTime());
 
 Review comment:
   We will update this when used, so it seems safe that way. But when creating 
a PM instance from a ddb record, I feel like we would overwrite the 
last_updated with the mod_time, won't we?

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


With regards,
Apache Git Services

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

Reply via email to