steveloughran commented on a change in pull request #675: HADOOP-16085: use
object version or etags to protect against inconsistent read after
replace/overwrite
URL: https://github.com/apache/hadoop/pull/675#discussion_r276038407
##########
File path:
hadoop-tools/hadoop-aws/src/main/java/org/apache/hadoop/fs/s3a/S3AFileStatus.java
##########
@@ -54,12 +57,30 @@ public S3AFileStatus(boolean isemptydir,
public S3AFileStatus(Tristate isemptydir,
Path path,
String owner) {
- super(0, true, 1, 0, 0, 0,
- null, null, null, null,
+ this(isemptydir, path, owner, owner, 0, 0, null);
+ }
+
+ /**
+ * Create a directory status.
+ * @param isemptydir is this an empty directory?
+ * @param path the path
+ * @param owner the owner
+ * @param group the group
+ * @param modification_time the modification time
+ * @param access_time the access time
+ * @param permission the permission
+ */
+ public S3AFileStatus(Tristate isemptydir,
Review comment:
what's the reason for adding permissions here? There aren't any with S3 and
so the default of rwx is thrown up, for better or (sometimes) worse. The risk
is that if some restricted permissions are set then code may actually believe
those permissions are enforced, when they aren't. Same for (user, group)
----------------------------------------------------------------
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]