diff options
author | Tony Sun <tony.sun427@gmail.com> | 2020-08-28 12:56:00 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-08-28 15:56:00 -0400 |
commit | bb869c1c27354550309f025f98a49b193a492a1f (patch) | |
tree | 48c6217c272e83a5c0a885e9ef35ce8b911baca6 /src/mango | |
parent | 95a1f4e8fb420b9bd918849baefd116b2b3c0e8e (diff) | |
download | couchdb-bb869c1c27354550309f025f98a49b193a492a1f.tar.gz |
bypass partition query limit for mango (#3114)
When partition_query_limit is set for couch_mrview, it limits how many
docs can be scanned when executing partitioned queries. But this limits
mango's doc scans internally. This leads to documents not being scanned
to fulfill a query. This fixes:
https://github.com/apache/couchdb/issues/2795
Co-authored-by: Joan Touzet <wohali@users.noreply.github.com>
Diffstat (limited to 'src/mango')
-rw-r--r-- | src/mango/src/mango_cursor_view.erl | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/mango/src/mango_cursor_view.erl b/src/mango/src/mango_cursor_view.erl index 240ef501d..68d7c3b62 100644 --- a/src/mango/src/mango_cursor_view.erl +++ b/src/mango/src/mango_cursor_view.erl @@ -116,7 +116,11 @@ base_args(#cursor{index = Idx, selector = Selector} = Cursor) -> start_key = StartKey, end_key = EndKey, include_docs = true, - extra = [{callback, {?MODULE, view_cb}}, {selector, Selector}] + extra = [ + {callback, {?MODULE, view_cb}}, + {selector, Selector}, + {ignore_partition_query_limit, true} + ] }. |