Skip to content
Snippets Groups Projects
Commit 170b660b authored by Jeff Yemin's avatar Jeff Yemin Committed by Robert J. Moore
Browse files

Fixed incorrect creation of MongoDB URL for mongodb.writeConcern of journaled.

parent 808907d0
No related branches found
No related tags found
No related merge requests found
......@@ -76,7 +76,7 @@ public final class OptionsSupport {
result = addUrlOption(result, "w", "1");
}
else if ("journaled".equals(writeConcernType)) {
result = addUrlOption(result, "journal", "true");
result = addUrlOption(result, "j", "true");
}
else if ("replica_acknowledged".equals(writeConcernType)) {
result = addUrlOption(result, "w", "2");
......
......@@ -110,7 +110,7 @@ public class OptionsSupportTest {
assertThat(
updateUrl("mongodb://locahost:27017/?foo=bar",
props("mongodb.writeConcern", "journaled")),
is("mongodb://locahost:27017/?foo=bar&journal=true"));
is("mongodb://locahost:27017/?foo=bar&j=true"));
assertThat(
updateUrl("mongodb://locahost:27017/?foo=bar",
props("mongodb.writeConcern", "replica_acknowledged")),
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment