couchdb-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kocol...@apache.org
Subject [29/50] fabric commit: updated refs/heads/2971-count-distinct to 5d18415
Date Wed, 01 Mar 2017 16:38:27 GMT
Revert "Merge remote-tracking branch 'banjiewen/stale-stable-update'"

This reverts commit 508122c52731a9eac3e83f8d727f2355f019fe1f, reversing
changes made to d68a00fdeba9113bd1a3dd41d8e546b05bb2e533.


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

Branch: refs/heads/2971-count-distinct
Commit: a8e0e9549bb2a1181538ae433f1de78abadc41d5
Parents: fb4b6b3
Author: ILYA Khlopotov <iilyak@apache.org>
Authored: Mon Nov 14 13:10:39 2016 -0800
Committer: ILYA Khlopotov <iilyak@apache.org>
Committed: Mon Nov 14 13:10:39 2016 -0800

----------------------------------------------------------------------
 src/fabric_view.erl | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/couchdb-fabric/blob/a8e0e954/src/fabric_view.erl
----------------------------------------------------------------------
diff --git a/src/fabric_view.erl b/src/fabric_view.erl
index 01291a9..a766348 100644
--- a/src/fabric_view.erl
+++ b/src/fabric_view.erl
@@ -302,13 +302,14 @@ index_of(X, [X|_Rest], I) ->
 index_of(X, [_|Rest], I) ->
     index_of(X, Rest, I+1).
 
-get_shards(DbName, #mrargs{stable=true}) ->
+get_shards(DbName, #mrargs{stale=Stale})
+  when Stale == ok orelse Stale == update_after ->
     mem3:ushards(DbName);
-get_shards(DbName, #mrargs{stable=false}) ->
+get_shards(DbName, #mrargs{stale=false}) ->
     mem3:shards(DbName).
 
 maybe_update_others(DbName, DDoc, ShardsInvolved, ViewName,
-    #mrargs{update=lazy} = Args) ->
+    #mrargs{stale=update_after} = Args) ->
     ShardsNeedUpdated = mem3:shards(DbName) -- ShardsInvolved,
     lists:foreach(fun(#shard{node=Node, name=ShardName}) ->
         rpc:cast(Node, fabric_rpc, update_mrview, [ShardName, DDoc, ViewName, Args])


Mime
View raw message