Skip to content

Commit

Permalink
add missed MongoClientOptions
Browse files Browse the repository at this point in the history
  • Loading branch information
AlvaroVega committed Jun 18, 2024
1 parent 489c578 commit 6b46e17
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -616,7 +616,11 @@ private MongoDatabase getDatabase(String dbName) {
build());
}
} else {
client = new MongoClient(servers);
MongoClientOptions options = MongoClientOptions.builder()
.sslEnabled(sslEnabled)
.sslInvalidHostNameAllowed(sslInvalidHostNameAllowed)
.build();
client = new MongoClient(servers, options);
} // if else
} // if

Expand Down

0 comments on commit 6b46e17

Please sign in to comment.