rishabhdaim commented on code in PR #295:
URL: https://github.com/apache/jackrabbit-oak/pull/295#discussion_r963460555


##########
oak-store-document/src/main/java/org/apache/jackrabbit/oak/plugins/document/mongo/MongoDBConnection.java:
##########
@@ -61,16 +64,19 @@ final class MongoDBConnection {
     static MongoDBConnection newMongoDBConnection(@NotNull String uri,
                                                   @NotNull String name,
                                                   @NotNull MongoClock clock,
-                                                  int socketTimeout,
-                                                  boolean socketKeepAlive) {
+                                                  int socketTimeout) {
         CompositeServerMonitorListener serverMonitorListener = new 
CompositeServerMonitorListener();
-        MongoClientOptions.Builder options = 
MongoConnection.getDefaultBuilder();
-        options.addServerMonitorListener(serverMonitorListener);
-        options.socketKeepAlive(socketKeepAlive);
+        MongoClientSettings.Builder options = 
MongoConnection.getDefaultBuilder();
+        options.applyToServerSettings((builder) -> {
+            builder.addServerMonitorListener(serverMonitorListener);
+        });
         if (socketTimeout > 0) {
-            options.socketTimeout(socketTimeout);
+            options.applyToSocketSettings((builder) -> {

Review Comment:
   Please see the above comment.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscr...@jackrabbit.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to