You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@couchdb.apache.org by rn...@apache.org on 2014/08/29 17:47:12 UTC
[1/2] couch commit: updated refs/heads/master to cb30f6a
Repository: couchdb-couch
Updated Branches:
refs/heads/master 95b60be72 -> cb30f6ac7
Revert "Fix match_spec's in couch_proc_manager"
This reverts commit 5f5aa98c4d558d8ff8caa24ade88483fd7f0c8bc.
Project: http://git-wip-us.apache.org/repos/asf/couchdb-couch/repo
Commit: http://git-wip-us.apache.org/repos/asf/couchdb-couch/commit/b0dd5464
Tree: http://git-wip-us.apache.org/repos/asf/couchdb-couch/tree/b0dd5464
Diff: http://git-wip-us.apache.org/repos/asf/couchdb-couch/diff/b0dd5464
Branch: refs/heads/master
Commit: b0dd54644abd8138e97253afb4534476cf4faa11
Parents: 95b60be
Author: Robert Newson <rn...@apache.org>
Authored: Fri Aug 29 16:32:56 2014 +0100
Committer: Robert Newson <rn...@apache.org>
Committed: Fri Aug 29 16:32:56 2014 +0100
----------------------------------------------------------------------
src/couch_proc_manager.erl | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/couchdb-couch/blob/b0dd5464/src/couch_proc_manager.erl
----------------------------------------------------------------------
diff --git a/src/couch_proc_manager.erl b/src/couch_proc_manager.erl
index 33ef06c..2b86af6 100644
--- a/src/couch_proc_manager.erl
+++ b/src/couch_proc_manager.erl
@@ -93,7 +93,7 @@ handle_call(get_proc_count, _From, State) ->
handle_call(get_stale_proc_count, _From, State) ->
#state{tab = Tab, threshold_ts = T0} = State,
- MatchSpec = [{#proc_int{t0='$1', _='_'}, [{'<', '$1', {T0}}], [true]}],
+ MatchSpec = [{#proc_int{t0='$1', _='_'}, [{'<', '$1', T0}], [true]}],
{reply, ets:select_count(Tab, MatchSpec), State};
handle_call({get_proc, #doc{body={Props}}=DDoc, DDocKey}, From, State) ->
@@ -148,7 +148,7 @@ handle_call(bump_threshold_ts, _From, #state{tab = Tab} = State) ->
handle_call(terminate_stale_procs, _From, State) ->
#state{tab = Tab, threshold_ts = T0} = State,
MatchHead = #proc_int{pid = '$1', t0 = '$2', _ = '_'},
- MatchSpec = [{MatchHead, [{'<', '$2', {T0}}], ['$1']}],
+ MatchSpec = [{MatchHead, [{'<', '$2', T0}], ['$1']}],
lists:foreach(fun(P) -> remove_proc(Tab,P) end, ets:select(Tab, MatchSpec)),
{reply, ok, State};
[2/2] couch commit: updated refs/heads/master to cb30f6a
Posted by rn...@apache.org.
don't count sys_dbs in open_databases
Project: http://git-wip-us.apache.org/repos/asf/couchdb-couch/repo
Commit: http://git-wip-us.apache.org/repos/asf/couchdb-couch/commit/cb30f6ac
Tree: http://git-wip-us.apache.org/repos/asf/couchdb-couch/tree/cb30f6ac
Diff: http://git-wip-us.apache.org/repos/asf/couchdb-couch/diff/cb30f6ac
Branch: refs/heads/master
Commit: cb30f6ac7ee7a52337666bc95a8b82cc558ad785
Parents: b0dd546
Author: Robert Newson <rn...@apache.org>
Authored: Fri Aug 29 16:45:47 2014 +0100
Committer: Robert Newson <rn...@apache.org>
Committed: Fri Aug 29 16:46:09 2014 +0100
----------------------------------------------------------------------
src/couch_db_updater.erl | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/couchdb-couch/blob/cb30f6ac/src/couch_db_updater.erl
----------------------------------------------------------------------
diff --git a/src/couch_db_updater.erl b/src/couch_db_updater.erl
index d8435a5..07518e4 100644
--- a/src/couch_db_updater.erl
+++ b/src/couch_db_updater.erl
@@ -61,7 +61,12 @@ init({DbName, Filepath, Fd, Options}) ->
end
end,
Db = init_db(DbName, Filepath, Fd, Header, Options),
- couch_stats_process_tracker:track([couchdb, open_databases]),
+ case lists:member(sys_db, Options) of
+ false ->
+ couch_stats_process_tracker:track([couchdb, open_databases]);
+ true ->
+ ok
+ end,
% we don't load validation funs here because the fabric query is liable to
% race conditions. Instead see couch_db:validate_doc_update, which loads
% them lazily