Details
-
Bug
-
Status: Open
-
Major
-
Resolution: Unresolved
-
1.32.0
-
None
-
None
Description
oak-store-document integration tests fails on Mongo when mongo is started with authentication enabled. When we pass mongo.url with credentials, in code at some point it doesn't pick the provided uri and evaluates uri again without credentials causing this issue. Below error "command listCollections requires authentication" is seen frequently while running tests:
[ERROR] medium(org.apache.jackrabbit.oak.plugins.document.blob.ds.DocumentMKDataStoreGetLengthTest) Time elapsed: 0.008 s <<< ERROR!
com.mongodb.MongoCommandException: Command failed with error 13 (Unauthorized): 'command listCollections requires authentication' on server localhost:27017. The full response is { "ok" : 0.0, "errmsg" : "command listCollections requires authentication", "code" : 13, "codeName" : "Unauthorized" }
at org.apache.jackrabbit.oak.plugins.document.blob.ds.DocumentMKDataStoreGetLengthTest.setUpConnection(DocumentMKDataStoreGetLengthTest.java:51)
[ERROR] medium(org.apache.jackrabbit.oak.plugins.document.blob.ds.DocumentMKDataStoreGetLengthTest) Time elapsed: 0.008 s <<< ERROR!
java.lang.NullPointerException
at org.apache.jackrabbit.oak.plugins.document.blob.ds.DocumentMKDataStoreGetLengthTest.tearDownConnection(DocumentMKDataStoreGetLengthTest.java:61)