[
https://issues.apache.org/jira/browse/HADOOP-17365?focusedWorklogId=510908&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-510908
]
ASF GitHub Bot logged work on HADOOP-17365:
-------------------------------------------
Author: ASF GitHub Bot
Created on: 12/Nov/20 17:15
Start Date: 12/Nov/20 17:15
Worklog Time Spent: 10m
Work Description: steveloughran commented on pull request #2447:
URL: https://github.com/apache/hadoop/pull/2447#issuecomment-726215491
ok, so the FS contract says rename-over-file should be rejected. S3A doesn't
do that, but then we have to worry about delayed consistency, where a newly
deleted file may still be found with HEAD, so we have to go with allowing the
rename to succeed. Pity
1. yes, contract.xml should be fixable. If you could supply a patch with the
option that'd be great
1. consider the fact that you've caught where s3a is wrong to be a success
of the test case
----------------------------------------------------------------
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: 510908)
Time Spent: 1h 50m (was: 1h 40m)
> Contract test for renaming over existing file is too lenient
> ------------------------------------------------------------
>
> Key: HADOOP-17365
> URL: https://issues.apache.org/jira/browse/HADOOP-17365
> Project: Hadoop Common
> Issue Type: Bug
> Components: test
> Reporter: Attila Doroszlai
> Assignee: Attila Doroszlai
> Priority: Minor
> Labels: pull-request-available
> Fix For: 3.3.1
>
> Time Spent: 1h 50m
> Remaining Estimate: 0h
>
> {{AbstractContractRenameTest#testRenameFileOverExistingFile}} is too lenient
> in its assertions.
> * {{FileAlreadyExistsException}} is accepted regardless of "rename
> overwrites" and "rename returns false if exists" contract options. I think
> it should be accepted only if both of those options are false.
> * "rename returns false if exists" option is ignored if the file is not
> overwritten by the implementation.
> Also, I think the "rename returns false if exists" option is incorrectly
> inverted in the test, which it can get away with because the checks are loose.
> (Found this while looking at a change in Ozone FS implementation from
> throwing exception to returning false. The contract test unexpectedly passed
> without changing {{contract.xml}}.)
--
This message was sent by Atlassian Jira
(v8.3.4#803005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]