adoroszlai opened a new pull request #2447:
URL: https://github.com/apache/hadoop/pull/2447


   ## What changes were proposed in this pull request?
   
   Add some assertions to make sure the result of `rename()` over existing file
   more closely matches expectations defined by contract options
   `rename-returns-false-if-dest-exists` and `rename-overwrites-dest`.
   
   https://issues.apache.org/jira/browse/HADOOP-17365
   
   ## How was this patch tested?
   
   Ran related contract tests in Hadoop project:
   
   ```
   Tests run: 11, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 1.025 s - 
in org.apache.hadoop.fs.contract.rawlocal.TestRawlocalContractRename
   Tests run: 10, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.993 s - 
in org.apache.hadoop.fs.contract.localfs.TestLocalFSContractRename
   Tests run: 10, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 4.654 s - 
in org.apache.hadoop.fs.contract.hdfs.TestHDFSContractRename
   Tests run: 10, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 12.14 s - 
in org.apache.hadoop.fs.contract.router.TestRouterHDFSContractRename
   Tests run: 10, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 13.295 s - 
in org.apache.hadoop.fs.contract.router.web.TestRouterWebHDFSContractRename
   ```
   
   (also some others for S3A and Azure, but tests in those were skipped).
   
   
   Also ran Ozone [rename contract 
test](https://github.com/apache/ozone/blob/master/hadoop-ozone/integration-test/src/test/java/org/apache/hadoop/fs/ozone/contract/ITestOzoneContractRename.java)
 with various combinations of these two contract options after overriding 
`testRenameFileOverExistingFile()`.


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



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

Reply via email to