I am currently configuring CAS 4.2.6 with the Docker image 
here: https://github.com/apereo/cas/tree/dockerized-caswebapp
Using the template from here: https://github.com/apereo/cas-overlay-template

The template and docker container seem to work out of the box, my troubles 
are connecting to Active Directory (using ldaptive).

I have tried a few deployerContextConfig scenarios now, and when I have one 
that seems to work, it's failing with this error being the primary cause:

Caused by: org.springframework.beans.factory.BeanCreationException: Error 
creating bean with name 'authenticator': Cannot create inner bean '(inner 
bean)#77cf329d' of type [org.ldaptive.auth.PooledSearchDnResolver] while 
setting constructor argument; nested exception is org.springframework.beans.
factory.BeanCreationException: Error creating bean with name '(inner 
bean)#77cf329d': Cannot create inner bean '(inner bean)#6e78177b' of type [
org.ldaptive.pool.PooledConnectionFactory] while setting bean property 
'connectionFactory'; nested exception is org.springframework.beans.factory.
BeanCreationException: Error creating bean with name '(inner bean)#6e78177b'
: Cannot create inner bean '(inner bean)#798b36fd' of type [org.ldaptive.
pool.BlockingConnectionPool] while setting bean property 'connectionPool'; 
nested exception is org.springframework.beans.factory.BeanCreationException: 
Error creating bean with name '(inner bean)#798b36fd': Cannot create inner 
bean '(inner bean)#20171cdc' of type [org.ldaptive.DefaultConnectionFactory] 
while setting bean property 'connectionFactory'; nested exception is org.
springframework.beans.factory.BeanCreationException: Error creating bean 
with name '(inner bean)#20171cdc': Cannot create inner bean '(inner 
bean)#6abb44cb' of type [org.ldaptive.ConnectionConfig] while setting bean 
property 'connectionConfig'; nested exception is org.springframework.beans.
factory.BeanCreationException: Error creating bean with name '(inner 
bean)#6abb44cb': Initialization of bean failed; nested exception is org.
springframework.beans.ConversionNotSupportedException: Failed to convert 
property value of type [java.lang.String] to required type [java.time.
Duration] for property 'connectTimeout'; nested exception is java.lang.
IllegalStateException: Cannot convert value of type [java.lang.String] to 
required type [java.time.Duration] for property 'connectTimeout': no 
matching editors or conversion strategy found

Seems like such a silly error, I have everything the same as others online, 
but have found no equivalent error reported..

Here's for reference:

Problematic code from deployerContextConfig.xml:

<ldaptive:ad-authenticator id="authenticator"
            ldapUrl="${ldap.url}"
            userFilter="${ldap.searchFilter}"
            bindDn="${ldap.managerDn}"
            bindCredential="${ldap.managerPassword}"
            allowMultipleDns="${ldap.allowMultipleDns:false}"
            *connectTimeout="${ldap.connectTimeout}"*
            validateOnCheckOut="${ldap.pool.validateOnCheckout}"
            failFastInitialize="true"
            blockWaitTime="${ldap.pool.blockWaitTime}"
            idleTime="${ldap.pool.idleTime}"
            baseDn="${ldap.baseDn}"
            maxPoolSize="${ldap.pool.maxSize}"
            minPoolSize="${ldap.pool.minSize}"
            validatePeriodically="${ldap.pool.validatePeriodically}"
            validatePeriod="${ldap.pool.validatePeriod}"
            prunePeriod="${ldap.pool.prunePeriod}"
            useSSL="${ldap.use.ssl:false}"
            subtreeSearch="${ldap.subtree.search:true}"
            useStartTLS="${ldap.useStartTLS}" />

snippet from cas.properties:

# LDAP connection timeout in milliseconds
ldap.connectTimeout=3000

from pom.xml:

<dependency>
<groupId>org.jasig.cas</groupId>
<artifactId>cas-server-support-ldap</artifactId>
<version>${cas.version}</version>
</dependency>
<dependency>
<groupId>org.ldaptive</groupId>
<artifactId>ldaptive</artifactId>
<version>1.2.0</version>
</dependency>

Possibly different version of ldaptive required?

-- 
CAS gitter chatroom: https://gitter.im/apereo/cas
CAS mailing list guidelines: https://apereo.github.io/cas/Mailing-Lists.html
CAS documentation website: https://apereo.github.io/cas
CAS project website: https://github.com/apereo/cas
--- 
You received this message because you are subscribed to the Google Groups "CAS 
Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/a/apereo.org/group/cas-user/.
To view this discussion on the web visit 
https://groups.google.com/a/apereo.org/d/msgid/cas-user/092b46f1-172b-438f-8d94-34530d22f88d%40apereo.org.
For more options, visit https://groups.google.com/a/apereo.org/d/optout.

Reply via email to