Details
-
Sub-task
-
Status: Closed
-
Major
-
Resolution: Fixed
-
None
-
None
-
Reviewed
Description
If a file rename fails, NativeIO#renameTo includes more information about the root cause than a plain java.io.File#renameTo. The native code can throw an exception with a detailed error message and the errno on *nix or the value of GetLastError on Windows. This issue proposes to use NativeIO#renameTo inside or in place of Storage#rename to help improve diagnostics. The method falls back to java.io.File#renameTo if native code is not loaded, so this change would not introduce a compatibility problem for deployments running without native code.
Attachments
Attachments
Issue Links
- is related to
-
HADOOP-9590 Move to JDK7 improved APIs for file operations when available
- Open