Hi Christian,

I have this same issue when I use mvnw. I am using the cas-docker-webapp 
distribution with the cas-overlay-template.

The weird thing is that I have one machine that consistently compiles and 
runs fine. No matter what I do I can't get it to run on any other machine. 
I have saved the working container as a new image and tried to start it on 
a different machine, but I get the same error. If I rebuild the docker 
image it gives the same error. Nothing has worked so far!

The docker versions are the same 18.09.1 on the system where it works and 
systems where it doesn't. I'm running Ubuntu 18.04 and 16.04. I'm using 
docker to avoid these kinds of issues!

Help!

Simon



On Wednesday, February 27, 2019 at 6:49:08 AM UTC+11, Christian Poirier 
wrote:
>
> I found that it is spring-boot version 1.5.16.RELEASE requires the version 
> 3.4.3 of mongo-java-driver. What I have to do to override this library 
> version?
>
> Le mardi 26 février 2019 13:01:00 UTC-5, Christian Poirier a écrit :
>>
>> Supplement of information: 
>>
>> When I run gradlew dependencies, I have got 
>> org.mongodb:mongo-java-driver:3.8.2 -> 3.4.3
>>
>> Le mardi 26 février 2019 11:15:23 UTC-5, Christian Poirier a écrit :
>>>
>>> Hi
>>>
>>> I want to compile my CAS SERVER WEBAPP with the version 3.8.2 of 
>>> mongo-java-driver but it is stuck with the mongo-java-driver version 3.4.3 
>>> library even if version 3.8.2 is specified.
>>>
>>> I try to add this to my dependencies.gradle with no result
>>>
>>> configurations.all {
>>>     resolutionStrategy {
>>>         force "org.mongo:mongo-java-driver:$mongoDriverVersion"
>>>     }
>>> }
>>>
>>> I looked for the reference to version 3.4.3 but without success. Th 
>>> version 3.8.2 is referenced by the variable mongoDriverVersion in 
>>> gradle.properties.
>>>
>>> Using version 3.4.3 prevents CAS from using the SSL connection.
>>>
>>> Caused by: java.lang.NoSuchMethodError: 
>>> com.mongodb.MongoClientOptions$Builder.sslContext(Ljavax/net/ssl/SSLContext;)Lcom/mongodb/MongoClientOptions$Builder;
>>>         at 
>>> org.apereo.cas.mongo.MongoDbConnectionFactory.buildMongoDbClientOptions(MongoDbConnectionFactory.java:272)
>>>         at 
>>> org.apereo.cas.mongo.MongoDbConnectionFactory.buildMongoDbClient(MongoDbConnectionFactory.java:313)
>>>         at 
>>> org.apereo.cas.mongo.MongoDbConnectionFactory.buildMongoTemplate(MongoDbConnectionFactory.java:108)
>>>         at 
>>> org.apereo.cas.config.MongoDbTicketRegistryConfiguration.mongoDbTicketRegistryTemplate(MongoDbTicketRegistryConfiguration.java:69)
>>>         at 
>>> org.apereo.cas.config.MongoDbTicketRegistryConfiguration$$EnhancerBySpringCGLIB$$41e9ae3a.CGLIB$mongoDbTicketRegistryTemplate$0(<generated>)
>>>         at 
>>> org.apereo.cas.config.MongoDbTicketRegistryConfiguration$$EnhancerBySpringCGLIB$$41e9ae3a$$FastClassBySpringCGLIB$$33e747ec.invoke(<generated>)
>>>         at 
>>> org.springframework.cglib.proxy.MethodProxy.invokeSuper(MethodProxy.java:228)
>>>         at 
>>> org.springframework.context.annotation.ConfigurationClassEnhancer$BeanMethodInterceptor.intercept(ConfigurationClassEnhancer.java:358)
>>>         at 
>>> org.apereo.cas.config.MongoDbTicketRegistryConfiguration$$EnhancerBySpringCGLIB$$41e9ae3a.mongoDbTicketRegistryTemplate(<generated>)
>>>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>>         at 
>>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
>>>         at 
>>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>>>         at java.lang.reflect.Method.invoke(Method.java:498)
>>>         at 
>>> org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:162)
>>>
>>>

-- 
You received this message because you are subscribed to the Google Groups "CAS 
Developer" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
Visit this group at https://groups.google.com/a/apereo.org/group/cas-dev/.

Reply via email to