directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From smckin...@apache.org
Subject [directory-fortress-core] branch master updated: Add example of interpolation
Date Tue, 12 Nov 2019 14:28:35 GMT
This is an automated email from the ASF dual-hosted git repository.

smckinney pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/directory-fortress-core.git


The following commit(s) were added to refs/heads/master by this push:
     new 4a27cbf  Add example of interpolation
4a27cbf is described below

commit 4a27cbfc647abf8def4fe23b50b95e48aab536b8
Author: smckinney <smckinney@apache.org>
AuthorDate: Tue Nov 12 08:28:30 2019 -0600

    Add example of interpolation
---
 README-CONFIG.md | 60 ++++++++++++++++++++++++++++++++++++++++++++++----------
 1 file changed, 50 insertions(+), 10 deletions(-)

diff --git a/README-CONFIG.md b/README-CONFIG.md
index d3b07ab..cc291b9 100644
--- a/README-CONFIG.md
+++ b/README-CONFIG.md
@@ -31,24 +31,64 @@
 -------------------------------------------------------------------------------
 ## SECTION 1.  Fortress Configuration Subsystem Overview
 
-Fortress uses interpolation to weave values found in the following source property files
into its bootstrap configuration:
+Fortress uses interpolation to weave values located in source property files into target
configuration files.
 
-1. Apache Ant Property Files (source of substitution parameters):
+A. Option files containing environment specific values:
  * user.properties
  * [slapd.properties](./slapd.properties.example)
  * [build.properties](./build.properties.example)
-2. Apache Ant script:
+
+B. Source files containing substitution expressions :
+ * [fortress.properties.src](./config/fortress.properties.src)
+ * [refreshLDAPData.xml.src](./ldap/setup/refreshLDAPData-src.xml)
+ * [slapd.conf.src](./ldap/slapd.conf.src)  (if using openldap)
+
+C. Target files generated by Fortress:
+ * [fortress.properties](./config/fortress.properties)
+ * [refreshLDAPData.xml](./ldap/setup/refreshLDAPData.xml)
+ * [slapd.conf](./ldap/slapd.conf)  (if using openldap)
+
+D. Apache Ant script with the mapping rules: A -> B = C:
  * [build-config.xml](./build-config.xml)
 
-Which are used to produce new artifacts used by Fortress runtime (target files of substitution):
+  The substitution parameters found in B, as **@name@**, are placeholders for the actual
values found in A.  
+  These are used by an Ant config task (D) to replace values into the actual files (C) needed
by Fortress runtime.
+  This interpolation process seeds implementation specific variables into configuration targets.

+  For example, host names, ports, pw's (ldap server coordinates) are loaded into the target,
fortress.properties.
+  
+For Example:
+
+A. Snip from [fortress.properties.src](./config/fortress.properties.src)
+```
+# Host name and port of LDAP DIT:
+host=@LDAP_HOST@
+port=@LDAP_PORT@
+
+# Options are openldap or apacheds (default):
+ldap.server.type=@SERVER_TYPE@
+```
+
+B. Snip from [build.properties](./build.properties.example)
+```
+# These parameters point fortress to LDAP host:
+ldap.host=ldapvip.net
+ldap.port=389
+
+# This is default, tells fortress what type of ldap server in use:
+ldap.server.type=openldap
+```
 
-1. [fortress.properties](./config/fortress.properties.src)
-2. [refreshLDAPData.xml](./ldap/setup/refreshLDAPData-src.xml)
-3. [slapd.conf](./ldap/slapd.conf.src)  (if using openldap)
+C. Becomes snip from [fortress.properties](./config/fortress.properties):
+```
+# Host name and port of LDAP DIT:
+host=ldapvip.net
+port=389
+
+# Options are openldap or apacheds (default):
+ldap.server.type=openldap
+```
 
-  Notice the substitution parameters, **@name@**, contained within the above config artifacts.
 These are used by an Ant config task
-  to replace values into the actual target artifact using values found inside the source
property files.  Thus Fortress uses simple Apache Ant
-  substitution to seed implementation specific variables, e.g. host names, ports, pw's, into
its config artifacts used at runtime.
+*Note: Files from category C are generated during Fortress build and not checked into source.*
 
 -------------------------------------------------------------------------------
 ## SECTION 2.  Fortress Ant Property Files


Mime
View raw message