airavata-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From shame...@apache.org
Subject [1/2] airavata git commit: Create temp script file in local data dir instead of AIRAVATA_HOME/bin dir
Date Wed, 09 Sep 2015 19:22:09 GMT
Repository: airavata
Updated Branches:
  refs/heads/master ddc76d600 -> b0c793f06


Create temp script file in local data dir instead of AIRAVATA_HOME/bin dir


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

Branch: refs/heads/master
Commit: ab71e6ccf378924e708d61247fef4ab0be6581d9
Parents: 9e53560
Author: Shameera Rathanyaka <shameerainfo@gmail.com>
Authored: Wed Sep 9 15:21:19 2015 -0400
Committer: Shameera Rathanyaka <shameerainfo@gmail.com>
Committed: Wed Sep 9 15:21:19 2015 -0400

----------------------------------------------------------------------
 .../src/main/java/org/apache/airavata/gfac/core/GFacUtils.java | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/airavata/blob/ab71e6cc/modules/gfac/gfac-core/src/main/java/org/apache/airavata/gfac/core/GFacUtils.java
----------------------------------------------------------------------
diff --git a/modules/gfac/gfac-core/src/main/java/org/apache/airavata/gfac/core/GFacUtils.java
b/modules/gfac/gfac-core/src/main/java/org/apache/airavata/gfac/core/GFacUtils.java
index 1870255..4d125cf 100644
--- a/modules/gfac/gfac-core/src/main/java/org/apache/airavata/gfac/core/GFacUtils.java
+++ b/modules/gfac/gfac-core/src/main/java/org/apache/airavata/gfac/core/GFacUtils.java
@@ -970,8 +970,10 @@ public class GFacUtils {
             // creating a temporary file using pbs script generated above
             int number = new SecureRandom().nextInt();
             number = (number < 0 ? -number : number);
-            tempJobFile = new File(Integer.toString(number) + jobManagerConfiguration.getScriptExtension());
-            FileUtils.writeStringToFile(tempJobFile, scriptContent);
+
+	        tempJobFile = new File(ServerSettings.getLocalDataLocation(), Integer.toString(number)
+
+			        jobManagerConfiguration.getScriptExtension());
+	        FileUtils.writeStringToFile(tempJobFile, scriptContent);
             return tempJobFile;
         } catch (IOException e) {
             throw new GFacException("Error occurred while creating the temp job script file",
e);


Mime
View raw message