play.api.http.HttpErrorHandlerExceptions$$anon$1: Execution exception[[MongoTimeoutException: Timed out after 30000 ms while waiting for a server that matches ReadPreferenceServerSelector{readPreference=secondary}. Client view of cluster state is {type=UNKNOWN, servers=[{address=staging-node3.shaharma.com:27017, type=UNKNOWN, state=CONNECTING, exception={com.mongodb.MongoSecurityException: Exception authenticating MongoCredential{mechanism=SCRAM-SHA-1, userName='userId', source='events', password=<hidden>, mechanismProperties={}}}, caused by {com.mongodb.MongoCommandException: Command failed with error 18: 'Authentication failed.' on server staging-node3.shaharma.com:27017. The full response is { "ok" : 0.0, "code" : 18, "errmsg" : "Authentication failed." }}}]]]

Searched on Google with the first line of a JAVA stack trace?

We can recommend more relevant solutions and speed up debugging when you paste your entire stack trace with the exception message. Try a sample exception.

Recommended solutions based on your search

Samebug tips

Do you know how to solve this issue? Write a tip to help other users and build your expert profile.

Solutions on the web

via Stack Overflow by Prayag Upd
, 1 year ago
Execution exception[[MongoTimeoutException: Timed out after 30000 ms while waiting for a server that matches ReadPreferenceServerSelector{readPreference=secondary}. Client view of cluster state is {type=UNKNOWN, servers=[{address=staging-node3
via Stack Overflow by Lucas Soares
, 7 months ago
Execution exception[[SQLTransientConnectionException: HikariPool-1 - Connection is not available, request timed out after 37892ms.]]
via Stack Overflow by Tomas Landaeta
, 4 months ago
Execution exception[[SQLTimeoutException: Timeout after 60001ms of waiting for a connection.]]
via Stack Overflow by Андрей Юсупов
, 9 months ago
Execution exception[[SQLTimeoutException: Timeout after 1001ms of waiting for a connection.]]
via Stack Overflow by Андрей Юсупов
, 10 months ago
Execution exception[[SQLTimeoutException: Timeout after 1000ms of waiting for a connection.]]
via Stack Overflow by D4Developer
, 1 year ago
Execution exception[[CompletionException: org.apache.commons.mail.EmailException: Sending the email to the following server failed : smtp.gmail.com:465]]
play.api.http.HttpErrorHandlerExceptions$$anon$1: Execution exception[[MongoTimeoutException: Timed out after 30000 ms while waiting for a server that matches ReadPreferenceServerSelector{readPreference=secondary}. Client view of cluster state is {type=UNKNOWN, servers=[{address=staging-node3.shaharma.com:27017, type=UNKNOWN, state=CONNECTING, exception={com.mongodb.MongoSecurityException: Exception authenticating MongoCredential{mechanism=SCRAM-SHA-1, userName='userId', source='events', password=<hidden>, mechanismProperties={}}}, caused by {com.mongodb.MongoCommandException: Command failed with error 18: 'Authentication failed.' on server staging-node3.shaharma.com:27017. The full response is { "ok" : 0.0, "code" : 18, "errmsg" : "Authentication failed." }}}]]]
at com.mongodb.connection.BaseCluster.createTimeoutException(BaseCluster.java:369)
at com.mongodb.connection.BaseCluster.selectServer(BaseCluster.java:101)
at com.mongodb.binding.ClusterBinding$ClusterBindingConnectionSource.(ClusterBinding.java:75)
at com.mongodb.binding.ClusterBinding$ClusterBindingConnectionSource.(ClusterBinding.java:71)
at com.mongodb.binding.ClusterBinding.getReadConnectionSource(ClusterBinding.java:63)
at com.mongodb.operation.OperationHelper.withConnection(OperationHelper.java:210)
at com.mongodb.operation.DistinctOperation.execute(DistinctOperation.java:155)
at com.mongodb.operation.DistinctOperation.execute(DistinctOperation.java:61)
at com.mongodb.Mongo.execute(Mongo.java:773)
at com.mongodb.Mongo$2.execute(Mongo.java:760)

Users with the same issue

Samebug visitor profile picture
Unknown user
Once, 1 year ago
4 times, 1 day ago
6 times, 3 days ago
Once, 4 weeks ago
Once, 1 month ago

Write tip

Know the solutions? Share your knowledge to help other developers to debug faster.