diff options
author | Lingzhi Deng <lingzhi.deng@mongodb.com> | 2020-06-15 13:52:06 -0400 |
---|---|---|
committer | Evergreen Agent <no-reply@evergreen.mongodb.com> | 2020-06-15 21:17:51 +0000 |
commit | 1261db4a593fe06c5139fc0c9877c406d76b5bb4 (patch) | |
tree | c01de597d19ddc99496c8c5557ca04e9ae4d8cf3 /src/mongo/s/commands/cluster_distinct_cmd.cpp | |
parent | 97631cdd42360d4a2d07941ae989a0047707914e (diff) | |
download | mongo-1261db4a593fe06c5139fc0c9877c406d76b5bb4.tar.gz |
SERVER-48557: Omit cursor.atClusterTime field from read replies in transactions
Diffstat (limited to 'src/mongo/s/commands/cluster_distinct_cmd.cpp')
-rw-r--r-- | src/mongo/s/commands/cluster_distinct_cmd.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mongo/s/commands/cluster_distinct_cmd.cpp b/src/mongo/s/commands/cluster_distinct_cmd.cpp index 2f98bfbf195..7359c79e910 100644 --- a/src/mongo/s/commands/cluster_distinct_cmd.cpp +++ b/src/mongo/s/commands/cluster_distinct_cmd.cpp @@ -259,7 +259,8 @@ public: result.appendArray("values", b.obj()); // If mongos selected atClusterTime or received it from client, transmit it back. - if (repl::ReadConcernArgs::get(opCtx).getArgsAtClusterTime()) { + if (!opCtx->inMultiDocumentTransaction() && + repl::ReadConcernArgs::get(opCtx).getArgsAtClusterTime()) { result.append("atClusterTime"_sd, repl::ReadConcernArgs::get(opCtx).getArgsAtClusterTime()->asTimestamp()); } |