Details
-
Task
-
Status: Closed
-
Major - P3
-
Resolution: Fixed
-
None
Description
Description:
1. `$out` is now disallowed in the pipeline for a view.
2. Now, when creating a new view, the create function may not insert a valid view. This is because inserting a new view will cause the view catalog to be rebuilt (and reverified). If an existing invalid view (e.g. one that contains a `$out` pipeline stage) exists, then the server will error before inserting the new view.
Because using an existing view doesn't cause the view catalog to be verified, users will not be alerted while using the existing, invalid view. This behavior we believe would be unexpected and should be documented.
Scope of changes:
Impact to other docs outside of this product:
MVP:
Resources:
Engineering Ticket Description:
We seem to allow $out stage as part of view definition.
This is problematic for several reasons. One is that trying to append any stages (i.e. doing anything other than a simple find() on this view) will fail. The other is that running find on this view will blow away whatever is in the collection named in "$out" which is not an obvious outcome and unlikely to have a valid use case for it.
Attachments
Issue Links
- documents
-
SERVER-34902 view definitions should *not* allow $out as a stage
-
- Closed
-
- related to
-
DOCS-12086 Docs for SERVER-35419: Make diskRequirement in StageConstraints in DocumentSource reflect child pipeline requirements.
-
- Closed
-