summaryrefslogtreecommitdiff
path: root/src/mongo/tools
diff options
context:
space:
mode:
authorBenety Goh <benety@mongodb.com>2014-09-23 14:01:03 -0400
committerBenety Goh <benety@mongodb.com>2014-09-23 14:02:41 -0400
commit348bacb3695d439ace201c66cdd8c7a467aead58 (patch)
treeea17f5b73d70a233f113c63de8683af16c89315b /src/mongo/tools
parent2cc743d006a03e4da933168d1e70d9c1799df9f4 (diff)
downloadmongo-348bacb3695d439ace201c66cdd8c7a467aead58.tar.gz
SERVER-15246 added bson tool options to mongo shim
Diffstat (limited to 'src/mongo/tools')
-rw-r--r--src/mongo/tools/mongoshim_options.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/mongo/tools/mongoshim_options.cpp b/src/mongo/tools/mongoshim_options.cpp
index 53c4e98c23f..02483d7e1ff 100644
--- a/src/mongo/tools/mongoshim_options.cpp
+++ b/src/mongo/tools/mongoshim_options.cpp
@@ -58,6 +58,11 @@ namespace mongo {
return ret;
}
+ ret = addBSONToolOptions(options);
+ if (!ret.isOK()) {
+ return ret;
+ }
+
options->addOptionChaining("load", "load", moe::Switch,
"load data" );
@@ -124,6 +129,11 @@ namespace mongo {
return ret;
}
+ ret = storeBSONToolOptions(params, args);
+ if (!ret.isOK()) {
+ return ret;
+ }
+
mongoShimGlobalParams.load = params.count("load") > 0;
mongoShimGlobalParams.drop = params.count("drop") > 0;
mongoShimGlobalParams.upsert = params.count("upsert") > 0;