-
Type:
Improvement
-
Resolution: Fixed
-
Priority:
Major - P3
-
Affects Version/s: None
-
Component/s: Aggregation Framework
-
None
-
Fully Compatible
-
Query 2017-09-11, Query 2017-10-02, Query 2017-10-23
-
None
-
None
-
None
-
None
-
None
-
None
-
None
Causal consistency inserts readConcern
{level:"local", afterClusterTime: "xxxxx"}(https://github.com/mongodb/mongo/blob/r3.5.11/src/mongo/shell/mongo.js#L140-L166) into all commands hence to allow CC session support commands should not reject readConcern
{level:"local"} as it is a default readConcern level already.
the reject for non supported readConcern
should be left without changes.
[js_test:agg_hint] 2017-08-09T21:16:05.041+0000 cmd: {
[js_test:agg_hint] 2017-08-09T21:16:05.041+0000 "query" : {
[js_test:agg_hint] 2017-08-09T21:16:05.045+0000 "aggregate" : "test",
[js_test:agg_hint] 2017-08-09T21:16:05.046+0000 "pipeline" : [
[js_test:agg_hint] 2017-08-09T21:16:05.046+0000 {
[js_test:agg_hint] 2017-08-09T21:16:05.048+0000 "$match" : {
[js_test:agg_hint] 2017-08-09T21:16:05.048+0000 "x" : 3
[js_test:agg_hint] 2017-08-09T21:16:05.048+0000 }
[js_test:agg_hint] 2017-08-09T21:16:05.049+0000 }
[js_test:agg_hint] 2017-08-09T21:16:05.049+0000 ],
[js_test:agg_hint] 2017-08-09T21:16:05.049+0000 "hint" : "x_1",
[js_test:agg_hint] 2017-08-09T21:16:05.049+0000 "explain" : true,
[js_test:agg_hint] 2017-08-09T21:16:05.050+0000 "cursor" : {
[js_test:agg_hint] 2017-08-09T21:16:05.050+0000
[js_test:agg_hint] 2017-08-09T21:16:05.050+0000 },
[js_test:agg_hint] 2017-08-09T21:16:05.050+0000 "readConcern" : {
[js_test:agg_hint] 2017-08-09T21:16:05.051+0000 "afterClusterTime" : Timestamp(1502313364, 13),
[js_test:agg_hint] 2017-08-09T21:16:05.055+0000 "level" : "local"
[js_test:agg_hint] 2017-08-09T21:16:05.061+0000 }
[js_test:agg_hint] 2017-08-09T21:16:05.068+0000 },
[js_test:agg_hint] 2017-08-09T21:16:05.069+0000 "$readPreference" : {
[js_test:agg_hint] 2017-08-09T21:16:05.071+0000 "mode" : "secondary"
[js_test:agg_hint] 2017-08-09T21:16:05.071+0000 },
[js_test:agg_hint] 2017-08-09T21:16:05.071+0000 "$clusterTime" : {
[js_test:agg_hint] 2017-08-09T21:16:05.074+0000 "clusterTime" : Timestamp(1502313364, 13),
[js_test:agg_hint] 2017-08-09T21:16:05.074+0000 "signature" : {
[js_test:agg_hint] 2017-08-09T21:16:05.075+0000 "hash" : BinData(0,"H09GsI66Qu9sYoIExRAmnN6Ivyg="),
[js_test:agg_hint] 2017-08-09T21:16:05.075+0000 "keyId" : NumberLong("6452386646464659457")
[js_test:agg_hint] 2017-08-09T21:16:05.081+0000 }
[js_test:agg_hint] 2017-08-09T21:16:05.086+0000 }
[js_test:agg_hint] 2017-08-09T21:16:05.088+0000 }
[js_test:agg_hint] 2017-08-09T21:16:05.090+0000 res: {
[js_test:agg_hint] 2017-08-09T21:16:05.091+0000 "ok" : 0,
[js_test:agg_hint] 2017-08-09T21:16:05.092+0000 "errmsg" : "Aggregation explain does not support the 'readConcern' option",
[js_test:agg_hint] 2017-08-09T21:16:05.092+0000 "code" : 9,
[js_test:agg_hint] 2017-08-09T21:16:05.093+0000 "codeName" : "FailedToParse",
[js_test:agg_hint] 2017-08-09T21:16:05.093+0000 "$clusterTime" : {
[js_test:agg_hint] 2017-08-09T21:16:05.100+0000 "clusterTime" : Timestamp(1502313364, 13),
[js_test:agg_hint] 2017-08-09T21:16:05.100+0000 "signature" : {
[js_test:agg_hint] 2017-08-09T21:16:05.100+0000 "hash" : BinData(0,"H09GsI66Qu9sYoIExRAmnN6Ivyg="),
[js_test:agg_hint] 2017-08-09T21:16:05.103+0000 "keyId" : NumberLong("6452386646464659457")
[js_test:agg_hint] 2017-08-09T21:16:05.104+0000 }
[js_test:agg_hint] 2017-08-09T21:16:05.105+0000 },
[js_test:agg_hint] 2017-08-09T21:16:05.105+0000 "operationTime" : Timestamp(1502313364, 13)
[js_test:agg_hint] 2017-08-09T21:16:05.105+0000 }
also here:
s_test:views_count] 2017-08-09T19:03:41.791-0400 XXX runCommand: cmd: {
[js_test:views_count] 2017-08-09T19:03:41.791-0400 "query" : {
[js_test:views_count] 2017-08-09T19:03:41.792-0400 "explain" : {
[js_test:views_count] 2017-08-09T19:03:41.792-0400 "count" : "lessThanSevenView",
[js_test:views_count] 2017-08-09T19:03:41.792-0400 "query" : {
[js_test:views_count] 2017-08-09T19:03:41.792-0400
[js_test:views_count] 2017-08-09T19:03:41.792-0400 },
[js_test:views_count] 2017-08-09T19:03:41.792-0400 "fields" : {
[js_test:views_count] 2017-08-09T19:03:41.792-0400
[js_test:views_count] 2017-08-09T19:03:41.792-0400 }
[js_test:views_count] 2017-08-09T19:03:41.792-0400 },
[js_test:views_count] 2017-08-09T19:03:41.792-0400 "verbosity" : "queryPlanner",
[js_test:views_count] 2017-08-09T19:03:41.792-0400 "readConcern" : {
[js_test:views_count] 2017-08-09T19:03:41.793-0400 "afterClusterTime" : Timestamp(1502319821, 18),
[js_test:views_count] 2017-08-09T19:03:41.793-0400 "level" : "local"
[js_test:views_count] 2017-08-09T19:03:41.793-0400 }
[js_test:views_count] 2017-08-09T19:03:41.793-0400 },
[js_test:views_count] 2017-08-09T19:03:41.793-0400 "$readPreference" : {
[js_test:views_count] 2017-08-09T19:03:41.793-0400 "mode" : "secondary"
[js_test:views_count] 2017-08-09T19:03:41.793-0400 },
[js_test:views_count] 2017-08-09T19:03:41.793-0400 "$clusterTime" : {
[js_test:views_count] 2017-08-09T19:03:41.793-0400 "clusterTime" : Timestamp(1502319821, 18),
[js_test:views_count] 2017-08-09T19:03:41.793-0400 "signature" : {
[js_test:views_count] 2017-08-09T19:03:41.794-0400 "hash" : BinData(0,"JSpLnjCFZeSqWikBtZqtmZ2aaEs="),
[js_test:views_count] 2017-08-09T19:03:41.794-0400 "keyId" : NumberLong("6452414452082933761")
[js_test:views_count] 2017-08-09T19:03:41.794-0400 }
[js_test:views_count] 2017-08-09T19:03:41.794-0400 }
[js_test:views_count] 2017-08-09T19:03:41.794-0400 }
[js_test:views_count] 2017-08-09T19:03:41.795-0400 XXX runCommand: res: {
[js_test:views_count] 2017-08-09T19:03:41.795-0400 "ok" : 0,
[js_test:views_count] 2017-08-09T19:03:41.795-0400 "errmsg" : "Explain command on shard shard-rs0/greyparrot:20003,greyparrot:20004 failed, caused by: { ok: 0.0, errmsg: \"Aggregation explain does not support the 'readConcern' option\", code: 9, codeName: \"FailedToParse\" }",
[js_test:views_count] 2017-08-09T19:03:41.795-0400 "code" : 9,
[js_test:views_count] 2017-08-09T19:03:41.795-0400 "codeName" : "FailedToParse",
[js_test:views_count] 2017-08-09T19:03:41.795-0400 "$clusterTime" : {
[js_test:views_count] 2017-08-09T19:03:41.795-0400 "clusterTime" : Timestamp(1502319821, 18),
[js_test:views_count] 2017-08-09T19:03:41.795-0400 "signature" : {
[js_test:views_count] 2017-08-09T19:03:41.796-0400 "hash" : BinData(0,"JSpLnjCFZeSqWikBtZqtmZ2aaEs="),
[js_test:views_count] 2017-08-09T19:03:41.796-0400 "keyId" : NumberLong("6452414452082933761")
[js_test:views_count] 2017-08-09T19:03:41.796-0400 }
[js_test:views_count] 2017-08-09T19:03:41.796-0400 },
[js_test:views_count] 2017-08-09T19:03:41.796-0400 "operationTime" : Timestamp(1502319821, 18)
[js_test:views_count] 2017-08-09T19:03:41.796-0400 }