You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@couchdb.apache.org by ko...@apache.org on 2018/05/24 14:27:33 UTC
[couchdb] branch 1338-node-flavors updated: Let the ets table
update asynchronously
This is an automated email from the ASF dual-hosted git repository.
kocolosk pushed a commit to branch 1338-node-flavors
in repository https://gitbox.apache.org/repos/asf/couchdb.git
The following commit(s) were added to refs/heads/1338-node-flavors by this push:
new cde61b3 Let the ets table update asynchronously
cde61b3 is described below
commit cde61b34682fef6430277e56f8f1abfd9919f082
Author: Adam Kocoloski <ko...@apache.org>
AuthorDate: Thu May 24 10:26:05 2018 -0400
Let the ets table update asynchronously
The config listener runs in a separate process that does not have
write access to the mem3_nodes table. It should be sufficient to write
to the DB and let mem3_nodes pick up that update and send it to the
cache.
---
src/mem3/src/mem3_nodes.erl | 2 --
1 file changed, 2 deletions(-)
diff --git a/src/mem3/src/mem3_nodes.erl b/src/mem3/src/mem3_nodes.erl
index 33e8d06..db59e8c 100644
--- a/src/mem3/src/mem3_nodes.erl
+++ b/src/mem3/src/mem3_nodes.erl
@@ -116,7 +116,6 @@ initialize_nodelist() ->
#doc{id = SelfId} = Doc ->
update_metadata(Db, Doc, NodeProps)
end,
- % TODO is this ignoring any update we just made above?
Seq = couch_db:get_update_seq(Db),
couch_db:close(Db),
Seq.
@@ -184,7 +183,6 @@ update_metadata(Db, #doc{body = {DocProps}} = Doc, NewProps) ->
% internal doc state matches .ini
ok;
MergedProps ->
- ets:insert(?MODULE, {node(), MergedProps}),
NewDoc = Doc#doc{body = {MergedProps}},
{ok, _} = couch_db:update_doc(Db, NewDoc, [])
end,
--
To stop receiving notification emails like this one, please contact
kocolosk@apache.org.