summaryrefslogtreecommitdiff
path: root/mongoexport/main
diff options
context:
space:
mode:
authorGabriel Russell <gabriel.russell@mongodb.com>2015-07-14 17:45:00 -0400
committerGabriel Russell <gabriel.russell@mongodb.com>2015-07-15 14:55:22 -0400
commit02a6489acf39965b10615bbcfac7a56f51f2cb46 (patch)
tree37670ce92aea6ee4b0d09df1f0b776edb8f7eeb2 /mongoexport/main
parentec1cedd467bffdbdba684185e42d04c0ae9843c2 (diff)
downloadmongo-02a6489acf39965b10615bbcfac7a56f51f2cb46.tar.gz
TOOLS-814 use the correct flags everywhere
Diffstat (limited to 'mongoexport/main')
-rw-r--r--mongoexport/main/mongoexport.go7
1 files changed, 7 insertions, 0 deletions
diff --git a/mongoexport/main/mongoexport.go b/mongoexport/main/mongoexport.go
index 0d7397c97a1..6a0828a667e 100644
--- a/mongoexport/main/mongoexport.go
+++ b/mongoexport/main/mongoexport.go
@@ -52,6 +52,13 @@ func main() {
opts.ReplicaSetName = setName
provider, err := db.NewSessionProvider(*opts)
+
+ providerFlags := db.DisableSocketTimeout
+ if inputOpts.SlaveOk {
+ providerFlags = providerFlags | db.Monotonic
+ }
+ provider.SetFlags(providerFlags)
+
if err != nil {
log.Logf(log.Always, "error connecting to host: %v", err)
os.Exit(util.ExitError)