Uploaded image for project: 'Documentation'
  1. Documentation
  2. DOCS-11361

Document that views must be accessed via mongos in a sharded cluster

    XMLWordPrintableJSON

Details

    Description

      In a sharded cluster, a view can only be read by sending commands to a mongos. You cannot connect directly to a mongod and issue queries against the view, even if all of the dependent namespaces of the view happen to reside on the same server. Users that attempt to do this will get a CommandOnShardedViewNotSupportedOnMongod error.

      This behavior is accurate for all versions, so it would be nice to have this for both v3.4 and v3.6 documentation.

      Scanning quickly through the views documentation, it might make sense to put a note about this in any sections that describe limitations of views (perhaps in https://docs.mongodb.com/manual/core/views/ under the "Behavior" section).

      Attachments

        Activity

          People

            Unassigned Unassigned
            kyle.suarez@mongodb.com Kyle Suarez
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

            Dates

              Created:
              Updated:
              1 year, 14 weeks, 2 days ago