-
Type: Improvement
-
Resolution: Duplicate
-
Priority: Minor - P4
-
None
-
Affects Version/s: 6.0.2, 6.0.3, 6.0.4, 4.4.21
-
Component/s: None
-
None
-
Query Optimization
Hello.
I see a errors CommandOnShardedViewNotSupportedOnMongod in mongos.log:
{"t":{"$date":"2023-03-14T16:36:24.640+03:00"},"s":"I", "c":"QUERY", "id":4625501, "ctx":"conn26972","msg":"Unable to establish remote cursors","attr":{"error":{"code":169,"codeName":"CommandOnShardedViewNotSupportedOnMongod","errmsg":"Resolved views on sharded collections must be executed by mongos","resolvedView":{"ns":"testdb.test_col_3","pipeline":[{"$unionWith":{"coll":"test_col_1"}},{"$unionWith":{"coll":"test_col_2"}},{"$unionWith":{"coll":"test_col_3"}}],"collation":{"locale":"simple"}}},"nRemotes":0}}
when using .find() or .findOne() in a view that union sharded collections.
The data in the collections is accessible through the view, but what does this error mean? And what to do with it?
My configuration:
Sharded cluster in 3 shard (2 node + 1 arbiter in each) / debian 11(bullseye)
mongodb-database-tools 100.6.1 mongodb-mongosh 1.8.1 mongodb-org 6.0.4 mongodb-org-database 6.0.4 mongodb-org-database-tools-extra 6.0.4 mongodb-org-mongos 6.0.4 mongodb-org-server 6.0.4 mongodb-org-shell 6.0.4 mongodb-org-tools 6.0.4
- depends on
-
SERVER-88656 Make sharded time-series query kickback logs less scary
- Closed
- related to
-
SERVER-42282 Consider replacing CommandOnShardedViewNotSupportedOnMongod mechanism with rewrite / routing from shard
- Backlog