geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dwo...@apache.org
Subject svn commit: r537265 - in /geronimo/server/trunk/modules: geronimo-client-builder/src/main/java/org/apache/geronimo/client/builder/ geronimo-deployment/src/main/java/org/apache/geronimo/deployment/util/ geronimo-j2ee-builder/src/main/java/org/apache/ger...
Date Fri, 11 May 2007 19:02:06 GMT
Author: dwoods
Date: Fri May 11 12:02:05 2007
New Revision: 537265

URL: http://svn.apache.org/viewvc?view=rev&rev=537265
Log:
GERONIMO-3151 DeploymentUtil.recursiveDelete(File,Collection) is returning a collection of
File objects, whereas most builders are expecting Strings

Modified:
    geronimo/server/trunk/modules/geronimo-client-builder/src/main/java/org/apache/geronimo/client/builder/AppClientModuleBuilder.java
    geronimo/server/trunk/modules/geronimo-deployment/src/main/java/org/apache/geronimo/deployment/util/DeploymentUtil.java
    geronimo/server/trunk/modules/geronimo-j2ee-builder/src/main/java/org/apache/geronimo/j2ee/deployment/EARConfigBuilder.java
    geronimo/server/trunk/modules/geronimo-openejb-builder/src/main/java/org/apache/geronimo/openejb/deployment/EjbModuleBuilder.java
    geronimo/server/trunk/modules/geronimo-web-2.5-builder/src/main/java/org/apache/geronimo/web25/deployment/AbstractWebModuleBuilder.java

Modified: geronimo/server/trunk/modules/geronimo-client-builder/src/main/java/org/apache/geronimo/client/builder/AppClientModuleBuilder.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-client-builder/src/main/java/org/apache/geronimo/client/builder/AppClientModuleBuilder.java?view=diff&rev=537265&r1=537264&r2=537265
==============================================================================
--- geronimo/server/trunk/modules/geronimo-client-builder/src/main/java/org/apache/geronimo/client/builder/AppClientModuleBuilder.java
(original)
+++ geronimo/server/trunk/modules/geronimo-client-builder/src/main/java/org/apache/geronimo/client/builder/AppClientModuleBuilder.java
Fri May 11 12:02:05 2007
@@ -840,13 +840,13 @@
     }
 
     private boolean cleanupAppClientDir(File configurationDir) {
-        LinkedList cannotBeDeletedList = new LinkedList();
+        LinkedList<String> cannotBeDeletedList = new LinkedList<String>();
 
         if (!DeploymentUtil.recursiveDelete(configurationDir, cannotBeDeletedList)) {
             // Output a message to help user track down file problem
             log.warn("Unable to delete " + cannotBeDeletedList.size() +
                     " files while recursively deleting directory "
-                    + configurationDir + LINE_SEP +
+                    + configurationDir.getAbsolutePath() + LINE_SEP +
                     "The first file that could not be deleted was:" + LINE_SEP + "  " +
                     (!cannotBeDeletedList.isEmpty() ? cannotBeDeletedList.getFirst() : ""));
             return false;

Modified: geronimo/server/trunk/modules/geronimo-deployment/src/main/java/org/apache/geronimo/deployment/util/DeploymentUtil.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-deployment/src/main/java/org/apache/geronimo/deployment/util/DeploymentUtil.java?view=diff&rev=537265&r1=537264&r2=537265
==============================================================================
--- geronimo/server/trunk/modules/geronimo-deployment/src/main/java/org/apache/geronimo/deployment/util/DeploymentUtil.java
(original)
+++ geronimo/server/trunk/modules/geronimo-deployment/src/main/java/org/apache/geronimo/deployment/util/DeploymentUtil.java
Fri May 11 12:02:05 2007
@@ -299,9 +299,12 @@
                         recursiveDelete(file, unableToDeleteCollection);
                     } else {
                         if (!file.delete() && unableToDeleteCollection != null) {
-                            unableToDeleteCollection.add(file);    
+                            unableToDeleteCollection.add(file.getAbsolutePath());    
                         }
                     }
+                    // help out the GC of file handles by nulling the references
+                    file = null;
+                    files[i] = null;
                 }
             }
         }

Modified: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/main/java/org/apache/geronimo/j2ee/deployment/EARConfigBuilder.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-j2ee-builder/src/main/java/org/apache/geronimo/j2ee/deployment/EARConfigBuilder.java?view=diff&rev=537265&r1=537264&r2=537265
==============================================================================
--- geronimo/server/trunk/modules/geronimo-j2ee-builder/src/main/java/org/apache/geronimo/j2ee/deployment/EARConfigBuilder.java
(original)
+++ geronimo/server/trunk/modules/geronimo-j2ee-builder/src/main/java/org/apache/geronimo/j2ee/deployment/EARConfigBuilder.java
Fri May 11 12:02:05 2007
@@ -681,7 +681,7 @@
             // Output a message to help user track down file problem
             log.warn("Unable to delete " + cannotBeDeletedList.size() +
                     " files while recursively deleting directory "
-                    + configurationDir + LINE_SEP +
+                    + configurationDir.getAbsolutePath() + LINE_SEP +
                     "The first file that could not be deleted was:" + LINE_SEP + "  " +
                     (!cannotBeDeletedList.isEmpty() ? cannotBeDeletedList.getFirst() : ""));
             return false;

Modified: geronimo/server/trunk/modules/geronimo-openejb-builder/src/main/java/org/apache/geronimo/openejb/deployment/EjbModuleBuilder.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-openejb-builder/src/main/java/org/apache/geronimo/openejb/deployment/EjbModuleBuilder.java?view=diff&rev=537265&r1=537264&r2=537265
==============================================================================
--- geronimo/server/trunk/modules/geronimo-openejb-builder/src/main/java/org/apache/geronimo/openejb/deployment/EjbModuleBuilder.java
(original)
+++ geronimo/server/trunk/modules/geronimo-openejb-builder/src/main/java/org/apache/geronimo/openejb/deployment/EjbModuleBuilder.java
Fri May 11 12:02:05 2007
@@ -416,7 +416,7 @@
             // Output a message to help user track down file problem
             log.warn("Unable to delete " + cannotBeDeletedList.size() +
                     " files while recursively deleting directory "
-                    + configurationDir + LINE_SEP +
+                    + configurationDir.getAbsolutePath() + LINE_SEP +
                     "The first file that could not be deleted was:" + LINE_SEP + "  " +
                     (!cannotBeDeletedList.isEmpty() ? cannotBeDeletedList.getFirst() : ""));
             return false;

Modified: geronimo/server/trunk/modules/geronimo-web-2.5-builder/src/main/java/org/apache/geronimo/web25/deployment/AbstractWebModuleBuilder.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-web-2.5-builder/src/main/java/org/apache/geronimo/web25/deployment/AbstractWebModuleBuilder.java?view=diff&rev=537265&r1=537264&r2=537265
==============================================================================
--- geronimo/server/trunk/modules/geronimo-web-2.5-builder/src/main/java/org/apache/geronimo/web25/deployment/AbstractWebModuleBuilder.java
(original)
+++ geronimo/server/trunk/modules/geronimo-web-2.5-builder/src/main/java/org/apache/geronimo/web25/deployment/AbstractWebModuleBuilder.java
Fri May 11 12:02:05 2007
@@ -667,7 +667,7 @@
             // Output a message to help user track down file problem
             log.warn("Unable to delete " + cannotBeDeletedList.size() +
                     " files while recursively deleting directory "
-                    + configurationDir + LINE_SEP +
+                    + configurationDir.getAbsolutePath() + LINE_SEP +
                     "The first file that could not be deleted was:" + LINE_SEP + "  " +
                     (!cannotBeDeletedList.isEmpty() ? cannotBeDeletedList.getFirst() : ""));
             return false;



Mime
View raw message