aboutsummaryrefslogtreecommitdiffstats
path: root/lib/diameter/src/base
diff options
context:
space:
mode:
authorAnders Svensson <[email protected]>2019-04-14 15:20:24 +0200
committerAnders Svensson <[email protected]>2019-04-14 16:21:40 +0200
commit82135c10177c9e773b1bc94c327f3744a9025491 (patch)
treed66e9a14d9945a5e94dbe5384fd03a5a44534727 /lib/diameter/src/base
parent37df105ad012683de1de4a1db40818dde9c7f3bd (diff)
downloadotp-82135c10177c9e773b1bc94c327f3744a9025491.tar.gz
otp-82135c10177c9e773b1bc94c327f3744a9025491.tar.bz2
otp-82135c10177c9e773b1bc94c327f3744a9025491.zip
Add appup and code_change
For the parent commit as a diameter 2.2 patch.
Diffstat (limited to 'lib/diameter/src/base')
-rw-r--r--lib/diameter/src/base/diameter_dist.erl9
1 files changed, 9 insertions, 0 deletions
diff --git a/lib/diameter/src/base/diameter_dist.erl b/lib/diameter/src/base/diameter_dist.erl
index 963db71260..ed23152b8b 100644
--- a/lib/diameter/src/base/diameter_dist.erl
+++ b/lib/diameter/src/base/diameter_dist.erl
@@ -522,5 +522,14 @@ terminate(_, _) ->
%% code_change/3
+%% Old code inadvertently monitored all nodes: start a new
+%% subscription and remove the old one.
+code_change(_OldVsn, State, "2.2") ->
+ ok = net_kernel:monitor_nodes(true, [{node_type, visible},
+ nodedown_reason]),
+ ok = net_kernel:monitor_nodes(false, [{node_type, all},
+ nodedown_reason]),
+ {ok, State};
+
code_change(_OldVsn, State, _Extra) ->
{ok, State}.