diff --git a/cas-server-support-ldap-monitor/.gitignore b/cas-server-support-ldap-monitor/.gitignore new file mode 100644 index 000000000000..1864be3afd65 --- /dev/null +++ b/cas-server-support-ldap-monitor/.gitignore @@ -0,0 +1,2 @@ +ad.properties +openldap.properties diff --git a/cas-server-support-ldap-monitor/pom.xml b/cas-server-support-ldap-monitor/pom.xml new file mode 100644 index 000000000000..6c9891046623 --- /dev/null +++ b/cas-server-support-ldap-monitor/pom.xml @@ -0,0 +1,81 @@ + + + + + + org.jasig.cas + cas-server + 4.2.0-SNAPSHOT + + 4.0.0 + cas-server-support-ldap-monitor + jar + Apereo CAS LDAP Monitor Support + + + + serac + Marvin S. Addison + marvin.addison@gmail.com + -5 + + developer + maintainer + + + + + + + org.jasig.cas + cas-server-core + ${project.version} + + + org.jasig.cas + cas-server-support-ldap + ${project.version} + + + org.jasig.cas + cas-server-support-ldap + ${project.version} + test + test-jar + + + com.unboundid + unboundid-ldapsdk + test + + + org.ldaptive + ldaptive-unboundid + ${ldaptive.version} + test + + + + + ${project.parent.basedir} + + + diff --git a/cas-server-support-ldap/src/main/java/org/jasig/cas/monitor/ConnectionFactoryMonitor.java b/cas-server-support-ldap-monitor/src/main/java/org/jasig/cas/monitor/ConnectionFactoryMonitor.java similarity index 100% rename from cas-server-support-ldap/src/main/java/org/jasig/cas/monitor/ConnectionFactoryMonitor.java rename to cas-server-support-ldap-monitor/src/main/java/org/jasig/cas/monitor/ConnectionFactoryMonitor.java diff --git a/cas-server-support-ldap/src/main/java/org/jasig/cas/monitor/PooledConnectionFactoryMonitor.java b/cas-server-support-ldap-monitor/src/main/java/org/jasig/cas/monitor/PooledConnectionFactoryMonitor.java similarity index 100% rename from cas-server-support-ldap/src/main/java/org/jasig/cas/monitor/PooledConnectionFactoryMonitor.java rename to cas-server-support-ldap-monitor/src/main/java/org/jasig/cas/monitor/PooledConnectionFactoryMonitor.java diff --git a/cas-server-support-ldap/src/test/resources/ldap-monitor-test.xml b/cas-server-support-ldap-monitor/src/site/site.xml similarity index 53% rename from cas-server-support-ldap/src/test/resources/ldap-monitor-test.xml rename to cas-server-support-ldap-monitor/src/site/site.xml index 75c76c4c3430..a4d0a820aa99 100644 --- a/cas-server-support-ldap/src/test/resources/ldap-monitor-test.xml +++ b/cas-server-support-ldap-monitor/src/site/site.xml @@ -19,17 +19,10 @@ under the License. --> - - - - - - - + + + + + + + diff --git a/cas-server-support-ldap-monitor/src/test/java/org/jasig/cas/AllTestsSuite.java b/cas-server-support-ldap-monitor/src/test/java/org/jasig/cas/AllTestsSuite.java new file mode 100644 index 000000000000..9a5f67e26b74 --- /dev/null +++ b/cas-server-support-ldap-monitor/src/test/java/org/jasig/cas/AllTestsSuite.java @@ -0,0 +1,37 @@ +/* + * Licensed to Apereo under one or more contributor license + * agreements. See the NOTICE file distributed with this work + * for additional information regarding copyright ownership. + * Apereo licenses this file to you under the Apache License, + * Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a + * copy of the License at the following location: + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + */ +package org.jasig.cas; + +import org.jasig.cas.monitor.ConnectionFactoryMonitorTests; +import org.jasig.cas.monitor.PooledConnectionFactoryMonitorTests; +import org.junit.runner.RunWith; +import org.junit.runners.Suite; + +/** + * Test suite to run all LDAP tests. + * @author Misagh Moayyed + * @since 4.1.0 + */ +@RunWith(Suite.class) +@Suite.SuiteClasses({ + ConnectionFactoryMonitorTests.class, + PooledConnectionFactoryMonitorTests.class, +}) +public class AllTestsSuite { +} diff --git a/cas-server-support-ldap/src/test/java/org/jasig/cas/monitor/ConnectionFactoryMonitorTests.java b/cas-server-support-ldap-monitor/src/test/java/org/jasig/cas/monitor/ConnectionFactoryMonitorTests.java similarity index 100% rename from cas-server-support-ldap/src/test/java/org/jasig/cas/monitor/ConnectionFactoryMonitorTests.java rename to cas-server-support-ldap-monitor/src/test/java/org/jasig/cas/monitor/ConnectionFactoryMonitorTests.java diff --git a/cas-server-support-ldap/src/test/java/org/jasig/cas/monitor/PooledConnectionFactoryMonitorTests.java b/cas-server-support-ldap-monitor/src/test/java/org/jasig/cas/monitor/PooledConnectionFactoryMonitorTests.java similarity index 100% rename from cas-server-support-ldap/src/test/java/org/jasig/cas/monitor/PooledConnectionFactoryMonitorTests.java rename to cas-server-support-ldap-monitor/src/test/java/org/jasig/cas/monitor/PooledConnectionFactoryMonitorTests.java diff --git a/cas-server-support-ldap/src/test/resources/ldap-poolmonitor-test.xml b/cas-server-support-ldap-monitor/src/test/resources/ldap-poolmonitor-test.xml similarity index 100% rename from cas-server-support-ldap/src/test/resources/ldap-poolmonitor-test.xml rename to cas-server-support-ldap-monitor/src/test/resources/ldap-poolmonitor-test.xml diff --git a/cas-server-support-ldap-monitor/src/test/resources/log4j2.xml b/cas-server-support-ldap-monitor/src/test/resources/log4j2.xml new file mode 100644 index 000000000000..89f69628440b --- /dev/null +++ b/cas-server-support-ldap-monitor/src/test/resources/log4j2.xml @@ -0,0 +1,53 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/cas-server-support-ldap-monitor/src/test/resources/truststore.jks b/cas-server-support-ldap-monitor/src/test/resources/truststore.jks new file mode 100644 index 000000000000..cfa9a7bce120 Binary files /dev/null and b/cas-server-support-ldap-monitor/src/test/resources/truststore.jks differ diff --git a/cas-server-support-ldap/src/test/java/org/jasig/cas/AllTestsSuite.java b/cas-server-support-ldap/src/test/java/org/jasig/cas/AllTestsSuite.java index 4040c97775e5..2f69f4ffc5d9 100644 --- a/cas-server-support-ldap/src/test/java/org/jasig/cas/AllTestsSuite.java +++ b/cas-server-support-ldap/src/test/java/org/jasig/cas/AllTestsSuite.java @@ -19,8 +19,6 @@ package org.jasig.cas; import org.jasig.cas.authentication.LdapAuthenticationHandlerTests; -import org.jasig.cas.monitor.ConnectionFactoryMonitorTests; -import org.jasig.cas.monitor.PooledConnectionFactoryMonitorTests; import org.jasig.cas.userdetails.LdapUserDetailsServiceTests; import org.junit.runner.RunWith; import org.junit.runners.Suite; @@ -33,8 +31,6 @@ @RunWith(Suite.class) @Suite.SuiteClasses({ LdapAuthenticationHandlerTests.class, - ConnectionFactoryMonitorTests.class, - PooledConnectionFactoryMonitorTests.class, LdapUserDetailsServiceTests.class }) public class AllTestsSuite { diff --git a/pom.xml b/pom.xml index 97085a4e7b96..7971bf781ec2 100644 --- a/pom.xml +++ b/pom.xml @@ -1406,6 +1406,7 @@ cas-server-support-jpa-service-registry cas-server-support-ldap cas-server-support-ldap-service-registry + cas-server-support-ldap-monitor cas-server-support-openid cas-server-support-wsfederation cas-server-support-radius