summaryrefslogtreecommitdiff
path: root/src/mongo/db/operation_context.h
diff options
context:
space:
mode:
authorKaloian Manassiev <kaloian.manassiev@mongodb.com>2016-07-27 16:19:34 -0400
committerKaloian Manassiev <kaloian.manassiev@mongodb.com>2016-07-30 09:51:14 -0400
commit8c326de66475125ce755c52d36340b52f86ac64e (patch)
tree45ba12e37ddd23212a4df1289da7ea5d0a4557b3 /src/mongo/db/operation_context.h
parent1af99e48949f36754e2b877f1057bdaba0b83aea (diff)
downloadmongo-8c326de66475125ce755c52d36340b52f86ac64e.tar.gz
SERVER-25050 Set maxTimeMS on OperationContext on mongos
This change makes mongos commands to retrieve the maxTimeMS from the command and set it on the OperationContext.
Diffstat (limited to 'src/mongo/db/operation_context.h')
-rw-r--r--src/mongo/db/operation_context.h14
1 files changed, 10 insertions, 4 deletions
diff --git a/src/mongo/db/operation_context.h b/src/mongo/db/operation_context.h
index aadb6c9f981..eee6b98f48d 100644
--- a/src/mongo/db/operation_context.h
+++ b/src/mongo/db/operation_context.h
@@ -344,11 +344,17 @@ public:
}
/**
- * Returns the number of microseconds remaining for this operation's time limit, or the
- * special value Microseconds::max() if the operation has no time limit.
+ * Returns the number of milliseconds remaining for this operation's time limit or
+ * Milliseconds::max() if the operation has no time limit.
+ */
+ Milliseconds getRemainingMaxTimeMillis() const;
+
+ /**
+ * NOTE: This is a legacy "max time" method for controlling operation deadlines and it should
+ * not be used in new code. Use getRemainingMaxTimeMillis instead.
*
- * This is a legacy "max time" method for controlling operation deadlines. Prefer not to use it
- * in new code.
+ * Returns the number of microseconds remaining for this operation's time limit, or the special
+ * value Microseconds::max() if the operation has no time limit.
*/
Microseconds getRemainingMaxTimeMicros() const;