You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@directory.apache.org by cp...@apache.org on 2019/01/04 16:10:50 UTC
[1/4] directory-fortress-core git commit: FC-260 add external config
for start tls
Repository: directory-fortress-core
Updated Branches:
refs/heads/master 78119fcac -> 8d2c04e13
FC-260 add external config for start tls
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/25725400
Tree: http://git-wip-us.apache.org/repos/asf/directory-fortress-core/tree/25725400
Diff: http://git-wip-us.apache.org/repos/asf/directory-fortress-core/diff/25725400
Branch: refs/heads/master
Commit: 2572540024b83cf14b1dfeba9eef19cbea787880
Parents: c2062d5
Author: Chris Pike <cl...@psu.edu>
Authored: Tue Dec 18 13:48:56 2018 -0500
Committer: Chris Pike <cl...@psu.edu>
Committed: Tue Dec 18 13:48:56 2018 -0500
----------------------------------------------------------------------
.../org/apache/directory/fortress/core/GlobalIds.java | 1 +
.../org/apache/directory/fortress/core/util/Config.java | 11 ++++++++++-
2 files changed, 11 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/25725400/src/main/java/org/apache/directory/fortress/core/GlobalIds.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/GlobalIds.java b/src/main/java/org/apache/directory/fortress/core/GlobalIds.java
index 0678a85..055665b 100755
--- a/src/main/java/org/apache/directory/fortress/core/GlobalIds.java
+++ b/src/main/java/org/apache/directory/fortress/core/GlobalIds.java
@@ -493,6 +493,7 @@ public final class GlobalIds
// Used for TLS/SSL client-side configs:
public static final String ENABLE_LDAP_SSL = "enable.ldap.ssl";
+ public static final String ENABLE_LDAP_STARTTLS = "enable.ldap.starttls";
public static final String ENABLE_LDAP_SSL_DEBUG = "enable.ldap.ssl.debug";
public static final String TRUST_STORE = "trust.store";
public static final String TRUST_STORE_PW = "trust.store.password";
http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/25725400/src/main/java/org/apache/directory/fortress/core/util/Config.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/util/Config.java b/src/main/java/org/apache/directory/fortress/core/util/Config.java
index 90d169f..ce2d1ed 100755
--- a/src/main/java/org/apache/directory/fortress/core/util/Config.java
+++ b/src/main/java/org/apache/directory/fortress/core/util/Config.java
@@ -1,5 +1,5 @@
/*
- * Licensed to the Apache Software Foundation (ASF) under one
+cs * Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
@@ -67,6 +67,7 @@ public final class Config
private static final String EXT_LDAP_LOG_POOL_MIN = "fortress.min.log.conn";
private static final String EXT_LDAP_LOG_POOL_MAX = "fortress.max.log.conn";
private static final String EXT_ENABLE_LDAP_SSL = "fortress.enable.ldap.ssl";
+ private static final String EXT_ENABLE_LDAP_STARTTLS = "fortress.enable.ldap.starttls";
private static final String EXT_ENABLE_LDAP_SSL_DEBUG = "fortress.enable.ldap.ssl.debug";
private static final String EXT_TRUST_STORE = "fortress.trust.store";
private static final String EXT_TRUST_STORE_PW = "fortress.trust.store.password";
@@ -635,6 +636,14 @@ public final class Config
config.setProperty( GlobalIds.ENABLE_LDAP_SSL, szValue );
LOG.info( PREFIX, GlobalIds.ENABLE_LDAP_SSL, szValue );
}
+
+ // Check to see if start tls enabled parameter has been overridden by a system property:
+ szValue = System.getProperty( EXT_ENABLE_LDAP_STARTTLS );
+ if( StringUtils.isNotEmpty( szValue ))
+ {
+ config.setProperty( GlobalIds.ENABLE_LDAP_STARTTLS, szValue );
+ LOG.info( PREFIX, GlobalIds.ENABLE_LDAP_STARTTLS, szValue );
+ }
// Check to see if the ssl debug enabled parameter has been overridden by a system property:
szValue = System.getProperty( EXT_ENABLE_LDAP_SSL_DEBUG );
[2/4] directory-fortress-core git commit: FC-261 add pool config for
test while idle and evicition runs
Posted by cp...@apache.org.
FC-261 add pool config for test while idle and evicition runs
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/b8654795
Tree: http://git-wip-us.apache.org/repos/asf/directory-fortress-core/tree/b8654795
Diff: http://git-wip-us.apache.org/repos/asf/directory-fortress-core/diff/b8654795
Branch: refs/heads/master
Commit: b865479593ce9cadf9440f1a145477eaad225a37
Parents: c2062d5
Author: Chris Pike <cl...@psu.edu>
Authored: Tue Dec 18 14:25:08 2018 -0500
Committer: Chris Pike <cl...@psu.edu>
Committed: Tue Dec 18 14:25:08 2018 -0500
----------------------------------------------------------------------
.../org/apache/directory/fortress/core/GlobalIds.java | 4 ++++
.../fortress/core/ldap/LdapConnectionProvider.java | 13 +++++++++++++
2 files changed, 17 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/b8654795/src/main/java/org/apache/directory/fortress/core/GlobalIds.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/GlobalIds.java b/src/main/java/org/apache/directory/fortress/core/GlobalIds.java
index 0678a85..76934a0 100755
--- a/src/main/java/org/apache/directory/fortress/core/GlobalIds.java
+++ b/src/main/java/org/apache/directory/fortress/core/GlobalIds.java
@@ -481,6 +481,8 @@ public final class GlobalIds
public static final String LDAP_ADMIN_POOL_MAX = "max.admin.conn";
public static final String LDAP_ADMIN_POOL_UID = "admin.user";
public static final String LDAP_ADMIN_POOL_PW = "admin.pw";
+ public static final String LDAP_ADMIN_POOL_TEST_IDLE = "admin.conn.test.idle";
+ public static final String LDAP_ADMIN_POOL_EVICT_RUN_MILLIS = "admin.conn.evict.run.millis";
/**
* Used for ldap connection pool of log users.
@@ -489,6 +491,8 @@ public final class GlobalIds
public static final String LDAP_LOG_POOL_PW = "log.admin.pw";
public static final String LDAP_LOG_POOL_MIN = "min.log.conn";
public static final String LDAP_LOG_POOL_MAX = "max.log.conn";
+ public static final String LDAP_LOG_POOL_TEST_IDLE = "log.conn.test.idle";
+ public static final String LDAP_LOG_POOL_EVICT_RUN_MILLIS = "log.conn.evict.run.millis";
// Used for TLS/SSL client-side configs:
http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/b8654795/src/main/java/org/apache/directory/fortress/core/ldap/LdapConnectionProvider.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/directory/fortress/core/ldap/LdapConnectionProvider.java b/src/main/java/org/apache/directory/fortress/core/ldap/LdapConnectionProvider.java
index fb09931..c33f776 100644
--- a/src/main/java/org/apache/directory/fortress/core/ldap/LdapConnectionProvider.java
+++ b/src/main/java/org/apache/directory/fortress/core/ldap/LdapConnectionProvider.java
@@ -125,6 +125,13 @@ public class LdapConnectionProvider
int max = Config.getInstance().getInt( GlobalIds.LDAP_ADMIN_POOL_MAX, 10 );
int logmin = Config.getInstance().getInt( GlobalIds.LDAP_LOG_POOL_MIN, 1 );
int logmax = Config.getInstance().getInt( GlobalIds.LDAP_LOG_POOL_MAX, 10 );
+
+ boolean testWhileIdle = Config.getInstance().getBoolean( GlobalIds.LDAP_ADMIN_POOL_TEST_IDLE, true );
+ boolean logTestWhileIdle = Config.getInstance().getBoolean( GlobalIds.LDAP_LOG_POOL_TEST_IDLE, true );
+
+ int timeBetweenEvictionRunMillis = Config.getInstance().getInt( GlobalIds.LDAP_ADMIN_POOL_EVICT_RUN_MILLIS, 1000 * 60 * 30 );
+ int logTimeBetweenEvictionRunMillis = Config.getInstance().getInt( GlobalIds.LDAP_LOG_POOL_EVICT_RUN_MILLIS, 1000 * 60 * 30 );
+
LOG.info( "LDAP POOL: host=[{}], port=[{}], min=[{}], max=[{}]", host, port, min, max );
LdapConnectionConfig config = new LdapConnectionConfig();
@@ -193,6 +200,8 @@ public class LdapConnectionProvider
adminPool.setMaxActive( max );
adminPool.setMinIdle( min );
adminPool.setMaxIdle( -1 );
+ adminPool.setTestWhileIdle( testWhileIdle );
+ adminPool.setTimeBetweenEvictionRunsMillis( timeBetweenEvictionRunMillis );
//adminPool.setMaxWait( 0 );
// Create the User pool
@@ -202,6 +211,8 @@ public class LdapConnectionProvider
userPool.setMaxActive( max );
userPool.setMinIdle( min );
userPool.setMaxIdle( -1 );
+ userPool.setTestWhileIdle( testWhileIdle );
+ userPool.setTimeBetweenEvictionRunsMillis( timeBetweenEvictionRunMillis );
// This pool of access log connections is used by {@link org.apache.directory.fortress.AuditMgr}.
// To enable, set {@code log.admin.user} && {@code log.admin.pw} inside fortress.properties file:
@@ -243,6 +254,8 @@ public class LdapConnectionProvider
logPool.setWhenExhaustedAction( GenericObjectPool.WHEN_EXHAUSTED_GROW );
logPool.setMaxActive( logmax );
logPool.setMinIdle( logmin );
+ logPool.setTestWhileIdle( logTestWhileIdle );
+ logPool.setTimeBetweenEvictionRunsMillis( logTimeBetweenEvictionRunMillis );
}
}
[3/4] directory-fortress-core git commit: Merge branch 'feature/fc260'
Posted by cp...@apache.org.
Merge branch 'feature/fc260'
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/84c38140
Tree: http://git-wip-us.apache.org/repos/asf/directory-fortress-core/tree/84c38140
Diff: http://git-wip-us.apache.org/repos/asf/directory-fortress-core/diff/84c38140
Branch: refs/heads/master
Commit: 84c38140255274b9f1c74ee26f243d51b77ee1aa
Parents: 78119fc 2572540
Author: Chris Pike <cl...@psu.edu>
Authored: Fri Jan 4 11:10:12 2019 -0500
Committer: Chris Pike <cl...@psu.edu>
Committed: Fri Jan 4 11:10:12 2019 -0500
----------------------------------------------------------------------
.../org/apache/directory/fortress/core/GlobalIds.java | 1 +
.../org/apache/directory/fortress/core/util/Config.java | 11 ++++++++++-
2 files changed, 11 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
[4/4] directory-fortress-core git commit: Merge branch 'feature/fc261'
Posted by cp...@apache.org.
Merge branch 'feature/fc261'
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/8d2c04e1
Tree: http://git-wip-us.apache.org/repos/asf/directory-fortress-core/tree/8d2c04e1
Diff: http://git-wip-us.apache.org/repos/asf/directory-fortress-core/diff/8d2c04e1
Branch: refs/heads/master
Commit: 8d2c04e1343d32fc7595ec0ce5487668607be860
Parents: 84c3814 b865479
Author: Chris Pike <cl...@psu.edu>
Authored: Fri Jan 4 11:10:20 2019 -0500
Committer: Chris Pike <cl...@psu.edu>
Committed: Fri Jan 4 11:10:20 2019 -0500
----------------------------------------------------------------------
.../org/apache/directory/fortress/core/GlobalIds.java | 4 ++++
.../fortress/core/ldap/LdapConnectionProvider.java | 13 +++++++++++++
2 files changed, 17 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/directory-fortress-core/blob/8d2c04e1/src/main/java/org/apache/directory/fortress/core/GlobalIds.java
----------------------------------------------------------------------