couchdb-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kxe...@apache.org
Subject fabric commit: updated refs/heads/master to f418f0d
Date Sat, 31 Jan 2015 20:55:57 GMT
Repository: couchdb-fabric
Updated Branches:
  refs/heads/master a4d985252 -> f418f0df6


Handle empty list of id/revs in fabric_doc_missing_revs:go

When AllIdsRevs is an empty list the result will always be an empty
response. Handle this explicitly given there is no work to do
(attempting to delegate to the shards previously resulted in a timeout).

This closes #10

COUCHDB-2531

Signed-off-by: Alexander Shorin <kxepal@apache.org>


Project: http://git-wip-us.apache.org/repos/asf/couchdb-fabric/repo
Commit: http://git-wip-us.apache.org/repos/asf/couchdb-fabric/commit/f418f0df
Tree: http://git-wip-us.apache.org/repos/asf/couchdb-fabric/tree/f418f0df
Diff: http://git-wip-us.apache.org/repos/asf/couchdb-fabric/diff/f418f0df

Branch: refs/heads/master
Commit: f418f0df6f44ac35d29f467880b7759ef7d72aa2
Parents: a4d9852
Author: Will Holley <willholley@gmail.com>
Authored: Sat Jan 31 20:20:02 2015 +0000
Committer: Alexander Shorin <kxepal@apache.org>
Committed: Sat Jan 31 23:54:51 2015 +0300

----------------------------------------------------------------------
 src/fabric_doc_missing_revs.erl | 2 ++
 1 file changed, 2 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/couchdb-fabric/blob/f418f0df/src/fabric_doc_missing_revs.erl
----------------------------------------------------------------------
diff --git a/src/fabric_doc_missing_revs.erl b/src/fabric_doc_missing_revs.erl
index 1687111..993c21d 100644
--- a/src/fabric_doc_missing_revs.erl
+++ b/src/fabric_doc_missing_revs.erl
@@ -20,6 +20,8 @@
 go(DbName, AllIdsRevs) ->
     go(DbName, AllIdsRevs, []).
 
+go(_, [], _) ->
+    {ok, []};
 go(DbName, AllIdsRevs, Options) ->
     Workers = lists:map(fun({#shard{name=Name, node=Node} = Shard, IdsRevs}) ->
         Ref = rexi:cast(Node, {fabric_rpc, get_missing_revs, [Name, IdsRevs,


Mime
View raw message