You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@brooklyn.apache.org by he...@apache.org on 2015/05/22 11:05:05 UTC

[20/23] incubator-brooklyn git commit: add comment about mkdir, as per code review

add comment about mkdir, as per code review


Project: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/commit/17497370
Tree: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/tree/17497370
Diff: http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/diff/17497370

Branch: refs/heads/master
Commit: 17497370f58fe156f5ba2ed5829e9fc019a25117
Parents: 5236675
Author: Alex Heneveld <al...@cloudsoftcorp.com>
Authored: Fri May 22 10:02:14 2015 +0100
Committer: Alex Heneveld <al...@cloudsoftcorp.com>
Committed: Fri May 22 10:02:14 2015 +0100

----------------------------------------------------------------------
 .../java/brooklyn/entity/basic/EmptySoftwareProcessSshDriver.java  | 2 ++
 1 file changed, 2 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-brooklyn/blob/17497370/software/base/src/main/java/brooklyn/entity/basic/EmptySoftwareProcessSshDriver.java
----------------------------------------------------------------------
diff --git a/software/base/src/main/java/brooklyn/entity/basic/EmptySoftwareProcessSshDriver.java b/software/base/src/main/java/brooklyn/entity/basic/EmptySoftwareProcessSshDriver.java
index f7d1d3d..dbafa65 100644
--- a/software/base/src/main/java/brooklyn/entity/basic/EmptySoftwareProcessSshDriver.java
+++ b/software/base/src/main/java/brooklyn/entity/basic/EmptySoftwareProcessSshDriver.java
@@ -48,6 +48,7 @@ public class EmptySoftwareProcessSshDriver extends AbstractSoftwareProcessSshDri
         Map<String, String> installFiles = entity.getConfig(SoftwareProcess.INSTALL_FILES);
         Map<String, String> installTemplates = entity.getConfig(SoftwareProcess.INSTALL_TEMPLATES);
         if ((installFiles!=null && !installFiles.isEmpty()) || (installTemplates!=null && !installTemplates.isEmpty())) {
+            // only do this if there are files, to prevent unnecessary `mkdir`
             super.copyInstallResources();
         }
     }
@@ -57,6 +58,7 @@ public class EmptySoftwareProcessSshDriver extends AbstractSoftwareProcessSshDri
         Map<String, String> runtimeFiles = entity.getConfig(SoftwareProcess.RUNTIME_FILES);
         Map<String, String> runtimeTemplates = entity.getConfig(SoftwareProcess.RUNTIME_TEMPLATES);
         if ((runtimeFiles!=null && !runtimeFiles.isEmpty()) || (runtimeTemplates!=null && !runtimeTemplates.isEmpty())) {
+            // only do this if there are files, to prevent unnecessary `mkdir`
             super.copyRuntimeResources();
         }        
     }