Merge branch 'mem3'
Conflicts:
apps/couch/src/couch_btree.erl
apps/couch/src/couch_changes.erl
apps/couch/src/couch_db.erl
apps/couch/src/couch_db.hrl
apps/couch/src/couch_httpd_db.erl
apps/couch/src/couch_util.erl
apps/dynomite/ebin/dynomite.app
apps/dynomite/src/dynomite_couch_api.erl
apps/rexi/ebin/rexi.app
apps/rexi/src/rexi.erl
apps/rexi/src/rexi_server.erl
apps/showroom/src/showroom_db.erl
apps/showroom/src/showroom_sup.erl
apps/showroom/src/showroom_view_updater.erl
diff --git a/ebin/rexi.app b/ebin/rexi.app
index b00cc4f..6e80386 100644
--- a/ebin/rexi.app
+++ b/ebin/rexi.app
@@ -4,6 +4,5 @@
{modules, [rexi, rexi_app, rexi_sup, rexi_monitor, rexi_server]},
{registered, [rexi_sup, rexi_server]},
{applications, [kernel, stdlib]},
- {mod, {rexi_app,[]}},
- {start_phases, []}
+ {mod, {rexi_app,[]}}
]}.
\ No newline at end of file
diff --git a/src/rexi.erl b/src/rexi.erl
index a344af7..8f1d72b 100644
--- a/src/rexi.erl
+++ b/src/rexi.erl
@@ -26,7 +26,7 @@
%% process' dictionary as `rexi_from', so it has a way to communicate with you.
%% Second, the remote process is monitored. If it exits with a Reason other
%% than normal, Caller will receive a message of the form
-%% `{rexi_EXIT, Ref, Reason}' where Ref is the returned reference.
+%% `{Ref, {rexi_EXIT, Reason}}' where Ref is the returned reference.
-spec cast(node(), pid(), mfa()) -> reference().
cast(Node, Caller, MFA) ->
Ref = make_ref(),
diff --git a/src/rexi_server.erl b/src/rexi_server.erl
index 1589ba3..8b92227 100644
--- a/src/rexi_server.erl
+++ b/src/rexi_server.erl
@@ -1,6 +1,6 @@
-module(rexi_server).
-behaviour(gen_server).
--export([init/1, handle_call/3, handle_cast/2, handle_info/2, terminate/2,
+-export([init/1, handle_call/3, handle_cast/2, handle_info/2, terminate/2,
code_change/3]).
-export([start_link/0, init_p/2]).
@@ -18,7 +18,7 @@
{ok, #st{}}.
handle_call(_Request, _From, St) ->
- {reply, ok, St}.
+ {reply, ignored, St}.
handle_cast({doit, From, MFA}, #st{workers=Workers} = St) ->
{LocalPid, Ref} = spawn_monitor(?MODULE, init_p, [From, MFA]),
@@ -69,4 +69,4 @@
lists:keyfind(Ref, 2, List).
notify_caller({Caller, Ref}, Reason) ->
- spawn(erlang, send, [Caller, {rexi_EXIT, Ref, Reason}]).
+ Caller ! {Ref, {rexi_EXIT, Reason}}.