Details
-
Bug
-
Resolution: Done
-
Major
-
JBossAS-4.0.3 SP1, JBossAS-4.0.4.CR2
-
None
-
Medium
Description
FarmMemberService.performDeploy() calls File.renameTo() to move a replicated file from tmp to /farm. Per the Javadoc for File.renameTo():
"Many aspects of the behavior of this method are inherently
platform-dependent: The rename operation might not be able to move a
file from one filesystem to another, it might not be atomic, and it
might not succeed if a file with the destination abstract pathname
already exists. The return value should always be checked to make sure
that the rename operation was successful."
We've had reports of problems in the rename when tmp and farm were different filesystems.
If the rename fails, can we fall back on a copy-and-delete to move the file?