ace-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "J.W. Janssen (Commented) (JIRA)" <>
Subject [jira] [Commented] (ACE-155) Review all file renames and check if they can cause a move across volumes
Date Thu, 22 Mar 2012 13:40:22 GMT


J.W. Janssen commented on ACE-155:

Did a grep on the source tree of today (March, 22nd 2012, 14:00h), and got the following results:

* ace-configurator/src/test/java/org/apache/ace/configurator/    outFile.renameTo(dest);
* ace-configurator/src/test/java/org/apache/ace/configurator/    outFile.renameTo(dest);

* ace-deployment-verifier/src/main/java/org/apache/felix/framework/util/
   return oldFile.renameTo(newFile);
* ace-deployment-verifier/src/main/java/org/apache/felix/framework/util/
   return ((File) arg1).renameTo((File) arg2) ? Boolean.TRUE : Boolean.FALSE;

* ace-obr-metadata/src/main/java/org/apache/ace/obr/metadata/bindex/
                   renameOK = tempIndex.renameTo(index);

* ace-repository-impl/src/main/java/org/apache/ace/repository/impl/  
     if (!tempFile.renameTo(file)) {

All of these locations can potentially fail, as all of them use temporary files in some way.
A solution would be to use the "moveFile" method found in Commons-IO.

> Review all file renames and check if they can cause a move across volumes
> -------------------------------------------------------------------------
>                 Key: ACE-155
>                 URL:
>             Project: ACE
>          Issue Type: Task
>            Reporter: Marcel Offermans
> See ACE-154, if we do a cross volume rename to move a file, it will fail. Review the
rest of the codebase to ensure we're handling this correctly across the board.

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:!default.jspa
For more information on JIRA, see:


View raw message