ReactiveMongo scala connect to cluster

Multi tool use
ReactiveMongo scala connect to cluster
I need to connect my application to mongoDB, on Atlas Cluster.
My Application connects to mongodb with URI like
"mongodb://user:pass@host1:27017,host2:27017,host3:27017/mydb?ssl=true&replicaSet=replica&authSource=admin
I end up with this stacktrace:
java.lang.ExceptionInInitializerError
at controllers.LoginController$$anonfun$login$1$$anonfun$apply$26.apply(LoginController.scala:220)
at controllers.LoginController$$anonfun$login$1$$anonfun$apply$26.apply(LoginController.scala:217)
at scala.util.Success$$anonfun$map$1.apply(Try.scala:237)
at scala.util.Try$.apply(Try.scala:192)
at scala.util.Success.map(Try.scala:237)
at scala.concurrent.Future$$anonfun$map$1.apply(Future.scala:237)
at scala.concurrent.Future$$anonfun$map$1.apply(Future.scala:237)
at scala.concurrent.impl.CallbackRunnable.run(Promise.scala:36)
at scala.concurrent.impl.ExecutionContextImpl$AdaptedForkJoinTask.exec(ExecutionContextImpl.scala:121)
at scala.concurrent.forkjoin.ForkJoinTask.doExec(ForkJoinTask.java:260)
at scala.concurrent.forkjoin.ForkJoinPool$WorkQueue.runTask(ForkJoinPool.java:1339)
at scala.concurrent.forkjoin.ForkJoinPool.runWorker(ForkJoinPool.java:1979)
at scala.concurrent.forkjoin.ForkJoinWorkerThread.run(ForkJoinWorkerThread.java:107)
Caused by: reactivemongo.core.actors.Exceptions$NodeSetNotReachable: MongoError['The node set can not be reached! Please check your network connectivity (Supervisor-1/Connection-2)']
at reactivemongo.api.MongoConnection.reactivemongo$api$MongoConnection$$wait$1(api.scala:349)
at reactivemongo.api.MongoConnection$$anonfun$doRetry$1$1.apply(api.scala:366)
at reactivemongo.api.MongoConnection$$anonfun$doRetry$1$1.apply(api.scala:364)
at akka.pattern.FutureTimeoutSupport$$anonfun$after$1.liftedTree1$1(FutureTimeoutSupport.scala:25)
at akka.pattern.FutureTimeoutSupport$$anonfun$after$1.apply$mcV$sp(FutureTimeoutSupport.scala:25)
at akka.actor.Scheduler$$anon$4.run(Scheduler.scala:126)
at akka.dispatch.TaskInvocation.run(AbstractDispatcher.scala:39)
at akka.dispatch.ForkJoinExecutorConfigurator$AkkaForkJoinTask.exec(AbstractDispatcher.scala:415)
Anyone encountered something like this?
By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.
The error is quite explicit, the connection URI is probably not OK
– cchantep
Jul 3 at 7:42