nickva edited a comment on issue #1571: rexi_server dies without being restarted URL: https://github.com/apache/couchdb/issues/1571#issuecomment-414831604 In https://github.com/apache/couchdb/blob/master/src/rexi/src/rexi_sup.erl#L23 noticed it's one_for_one strategy, so if any of the top level children dies and restarts (like say rexi_sup did in the log), when rexi_sup respawns, nothing will restart all the rexi servers. `rexi_server_mon` only checks if it needs to restart servers on cluster membership changes and on startup: https://github.com/apache/couchdb/blob/master/src/rexi/src/rexi_server_mon.erl#L56-L63 So maybe we'd want a `rest_for_one` strategy in rexi_sup (in addition to increasing the intensity check timeout in rexi_server_sup?). ``` init([]) -> {ok, {{rest_for_one, 3, 10}, [ { rexi_server, {rexi_server, start_link, [rexi_server]}, permanent, 100, worker, [rexi_server] }, { rexi_server_sup, {rexi_server_sup, start_link, [rexi_server_sup]}, permanent, 100, supervisor, [rexi_server_sup] }, { rexi_server_mon, {rexi_server_mon, start_link, [rexi_server]}, permanent, 100, worker, [rexi_server_mon] }, { rexi_buffer_sup, {rexi_server_sup, start_link, [rexi_buffer_sup]}, permanent, 100, supervisor, [rexi_server_sup] }, { rexi_buffer_mon, {rexi_server_mon, start_link, [rexi_buffer]}, permanent, 100, worker, [rexi_server_mon] } ]}}. ``` In this case if `rexi_server_sup` dies, it will take down `rexi_server_mon` (well and unfortunately the buffers), but then on restart it will bring back `rexi_server_mon` and it should repopulate the servers in `rexi_server_sup`.
---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: [email protected] With regards, Apache Git Services
