directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From smckin...@apache.org
Subject directory-fortress-core git commit: FC-96 - Externalize fortress web.war config - add server type
Date Sun, 10 May 2015 13:15:22 GMT
Repository: directory-fortress-core
Updated Branches:
  refs/heads/master 5d04a6517 -> 1fc96e835


FC-96 - Externalize fortress web.war config - add server type


Project: http://git-wip-us.apache.org/repos/asf/directory-fortress-core/repo
Commit: http://git-wip-us.apache.org/repos/asf/directory-fortress-core/commit/1fc96e83
Tree: http://git-wip-us.apache.org/repos/asf/directory-fortress-core/tree/1fc96e83
Diff: http://git-wip-us.apache.org/repos/asf/directory-fortress-core/diff/1fc96e83

Branch: refs/heads/master
Commit: 1fc96e835d25747015e50032de4f17022618de5a
Parents: 5d04a65
Author: Shawn McKinney <smckinney@apache.org>
Authored: Sun May 10 05:30:25 2015 -0500
Committer: Shawn McKinney <smckinney@apache.org>
Committed: Sun May 10 05:30:25 2015 -0500

----------------------------------------------------------------------
 .../java/org/apache/directory/fortress/core/cfg/Config.java  | 8 ++++++++
 1 file changed, 8 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/1fc96e83/src/main/java/org/apache/directory/fortress/core/cfg/Config.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/cfg/Config.java b/src/main/java/org/apache/directory/fortress/core/cfg/Config.java
index 6fd9873..2ba419a 100755
--- a/src/main/java/org/apache/directory/fortress/core/cfg/Config.java
+++ b/src/main/java/org/apache/directory/fortress/core/cfg/Config.java
@@ -64,6 +64,7 @@ public class Config
     final private static String EXT_TRUST_STORE_PW = "fortress.trust.store.password";
     final private static String EXT_SET_TRUST_STORE_PROP = "fortress.trust.store.set.prop";
     final private static String EXT_CONFIG_REALM = "fortress.config.realm";
+    final private static String EXT_SERVER_TYPE = "ldap.server.type";
     final private static PropertiesConfiguration config;
     final private static String CLS_NM = Config.class.getName();
     final private static Logger LOG = LoggerFactory.getLogger( CLS_NM );
@@ -466,5 +467,12 @@ public class Config
         {
             config.setProperty( GlobalIds.CONFIG_REALM, szValue );
         }
+
+        // Check to see if the ldap server type has been overriden by a system property:
+        szValue = System.getProperty( EXT_SERVER_TYPE  );
+        if( VUtil.isNotNullOrEmpty( szValue ))
+        {
+            config.setProperty( GlobalIds.SERVER_TYPE, szValue );
+        }
     }
 }
\ No newline at end of file


Mime
View raw message