runzhiwang opened a new pull request #1559: URL: https://github.com/apache/ozone/pull/1559
## What changes were proposed in this pull request? When use hive on ozone, I can not insert the second entry to created table, and exception thrown from ozone.  The following hive code will call ozone's `rename(src, dst)` method, but if the last file of src and dst is same, ozone will throw exception.  Then I tried hive on hdfs, I find hdfs's rename in this case will not throw exception, it just [return false](https://github.com/apache/hadoop/blob/trunk/hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/namenode/FSDirRenameOp.java#L186), then hive will change the dst patch at `destFilePath = new Path(destDirPath, name + ("_copy_" + counter) + (!type.isEmpty() ? "." + type : ""));`. So we should keep ozone and hdfs's behavior the same, so that hive can run on ozone. ## What is the link to the Apache JIRA https://issues.apache.org/jira/browse/HDDS-4435 ## How was this patch tested? No need to add new ut. ---------------------------------------------------------------- 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]
