Add $facet
complete
A
Adam Holt
It would be great if you could add the $facet aggregation for the stitch client SDK
Drew DiPalma
complete
Hi All –
The work to allow a broader set of CRUD/Aggregate commands within functions run as a System user is now complete. You can find documentation on System Users/Functions in the following locations:
https://docs.mongodb.com/stitch/functions/define-a-function/
https://docs.mongodb.com/stitch/authentication/#system-users
Please feel free to file an additional Canny item if there are cases which cannot be addressed by this improvement.
Thanks,
Drew
Simon Lawrence
Drew DiPalma: Unfortunately, this does not satisfy my use case of providing faceted filtering options to end-users, I've submitted a request to enable $facet in the application user context:
Whilst, I could perform the query in a function and return the results, this is far from ideal and is probably not performant enough.
Drew DiPalma
in progress
Hi Folks – We are working on an improvement that will allow a much broader range of MDB syntax within functions run as "System User" (allowing the function to skip rules). Alongside this work, I am putting this improvement into "In Progress." Please reach out if you have questions or have a case that may not be addressed by this work.
Drew DiPalma
Hi Adam - We are considering some work in the near term that would allow $facet to be run in a Stitch Function (which could then be called from the SDK). Does this fit your needs?