You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airavata.apache.org by di...@apache.org on 2019/06/05 23:05:10 UTC
[airavata] branch master updated: Externalizing local data dir
This is an automated email from the ASF dual-hosted git repository.
dimuthuupe pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/airavata.git
The following commit(s) were added to refs/heads/master by this push:
new 1ab8b73 Externalizing local data dir
1ab8b73 is described below
commit 1ab8b73acc69043536239cb0b909859f6fe0eb6a
Author: Dimuthu Wannipurage <di...@gmail.com>
AuthorDate: Wed Jun 5 19:04:58 2019 -0400
Externalizing local data dir
---
.../src/main/java/org/apache/airavata/common/utils/Constants.java | 2 ++
.../src/main/java/org/apache/airavata/common/utils/ServerSettings.java | 2 +-
2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/modules/commons/src/main/java/org/apache/airavata/common/utils/Constants.java b/modules/commons/src/main/java/org/apache/airavata/common/utils/Constants.java
index c5e2a79..8820d45 100644
--- a/modules/commons/src/main/java/org/apache/airavata/common/utils/Constants.java
+++ b/modules/commons/src/main/java/org/apache/airavata/common/utils/Constants.java
@@ -57,6 +57,8 @@ public final class Constants {
public static final String IN_MEMORY_CACHE_SIZE = "in.memory.cache.size";
+ public static final String LOCAL_DATA_LOCATION = "local.data.location";
+
//Names of the attributes that could be passed in the AuthzToken's claims map.
public static final String USER_NAME = "userName";
public static final String GATEWAY_ID = "gatewayID";
diff --git a/modules/commons/src/main/java/org/apache/airavata/common/utils/ServerSettings.java b/modules/commons/src/main/java/org/apache/airavata/common/utils/ServerSettings.java
index f5a44d7..e8ff43f 100644
--- a/modules/commons/src/main/java/org/apache/airavata/common/utils/ServerSettings.java
+++ b/modules/commons/src/main/java/org/apache/airavata/common/utils/ServerSettings.java
@@ -441,7 +441,7 @@ public class ServerSettings extends ApplicationSettings {
}
public static String getLocalDataLocation() {
- return System.getProperty("java.io.tmpdir");
+ return getSetting(Constants.LOCAL_DATA_LOCATION, System.getProperty("java.io.tmpdir"));
}
public static Boolean isEnableSharing() throws ApplicationSettingsException {