garrensmith commented on a change in pull request #1605: Feature/user
partitioned databases
URL: https://github.com/apache/couchdb/pull/1605#discussion_r225467392
##########
File path: src/fabric/src/fabric_view_all_docs.erl
##########
@@ -136,6 +136,28 @@ go(DbName, _Options, Workers, QueryArgs, Callback, Acc0)
->
{ok, Resp}
end.
+shards(DbName, Args) ->
+ case couch_mrview_util:get_extra(Args, partitioned) of
+ true ->
+ StartKey = partition(Args#mrargs.start_key),
+ EndKey = partition(Args#mrargs.end_key),
+ case {StartKey, EndKey} of
+ {Same, Same} when Same =/= undefined ->
+ mem3:shards(DbName, <<Same/binary, ":foo">>);
Review comment:
Yes. We just need a "fake" value to add to the key to make it a full id of
the format `Partition:Id`
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services