Skip to content

Commit

Permalink
DATAMONGO-2531 - Fix MongoClientSettings UUID configuration hook in M…
Browse files Browse the repository at this point in the history
…ongoConfigurationSupport.

Client code overriding configureClientSettings does not automatically remove the default UUidRepresentation settings.
  • Loading branch information
christophstrobl committed Apr 27, 2020
1 parent 96ff4e1 commit 26ddf9d
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -217,6 +217,7 @@ protected boolean autoIndexCreation() {
protected MongoClientSettings mongoClientSettings() {

MongoClientSettings.Builder builder = MongoClientSettings.builder();
builder.uuidRepresentation(UuidRepresentation.JAVA_LEGACY);
configureClientSettings(builder);
return builder.build();
}
Expand All @@ -228,6 +229,6 @@ protected MongoClientSettings mongoClientSettings() {
* @since 3.0
*/
protected void configureClientSettings(MongoClientSettings.Builder builder) {
builder.uuidRepresentation(UuidRepresentation.JAVA_LEGACY);
// customization hook
}
}

0 comments on commit 26ddf9d

Please sign in to comment.