Skip to content

Commit

Permalink
Merge remote-tracking branch 'couchbase/cheshire-cat'
Browse files Browse the repository at this point in the history
* MB-48047:[BP] Introduce inaddr_any/2
* MB-48047:[BP] Add functions which determine the specific os type
* MB-48047:[BP] Introduce misc:localhost/2
* MB-48047:[BP] Some refactor of webconfig function
* MB-48047:[BP] Remove support for MOCHIWEB_IP wasn't working anyway
* MB-48047:[BP] Remove support for MOCHIWEB_PORT
* MB-48047:[BP] Introduce new 'strict' cluster encryption level
* MB-48047:[BP] Enforce 'strict' encryption level in ns_server
* MB-48047:[BP] Make memcached interfaces address family specific
* MB-48047:[BP] Enforce 'strict' encryption level for memcached
* MB-48047:[BP] Refactor menelaus_web http server start code
* MB-48047:[BP] Slight refactor of menelaus_event code
* MB-48047:[BP] Separate gen_event and internal functions
* MB-48047:[BP] Start menelaus_event before menelaus_web in new sup
* MB-48047:[BP] Fix theoretical race in misc:start_event_link
* MB-48047:[BP] cb_dist: Disable ipv6 listener when ...
* MB-48047:[BP] Make engage cluster wait for web server restart
* MB-48047:[BP] cb_dist: Listen on loopback when possible
* MB-48047:[BP] cb_dist: Use IPv{4|6} instead of ipv{4|6}
* MB-48047:[BP] Enforce 'strict' clusterEncryptionLevel in CAPI
* MB-48047:[BP] Make switching to afamily for which we don't ...
* MB-48047:[BP] Add endpoint to disable unused cb_dist listeners
* MB-48047:[BP] flush accept messages after we kill the acceptor
* MB-48047:[BP] Graceful exit of connector won't work till ...
* MB-48047:[BP] Optionally register node with epmd.
* MB-48047:[BP] Conditionally kill epmd on settings change
* MB-48047:[BP] Set appropriate defaults for listeners
* MB-48047:[BP] restart cb_config_couch_sync on crash
* MB-48047:[BP] Always annouce cluster_encryption_level on start.
* MB-48047:[BP] Prevent socket close on clusterEncryptionLevel
* MB-48047:[BP] During config reload try connecting to kv on all
* MB-48047: Kill epmd when joining cluster if required.
* MB-48047:[BP] Make terminate timeout smaller

Change-Id: Ic9cdb294afa2c2bc38637c98f41bbee6805094b7
  • Loading branch information
anuthan committed Nov 9, 2021
2 parents 2c83669 + 85165f8 commit 6729aae
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/cb_dist.erl
Expand Up @@ -709,7 +709,7 @@ conf(Prop, Conf) ->
%% See comments for how we determine defaults.
proplists:get_value(Prop, Conf, proplists:get_value(Prop, defaults(Conf))).

%% From 7.0,
%% From 6.6.4,
%% 1. we do not start both [inet_tcp_dist, inet6_tcp_dist] protos for
%% local_listeners and external_listeners by default as we introduced the
%% address family only feature.
Expand Down
7 changes: 7 additions & 0 deletions src/misc.erl
Expand Up @@ -1494,6 +1494,13 @@ try_with_maybe_ignorant_after(TryBody, AfterBody) ->
letrec(Args, F) ->
erlang:apply(F, [F | Args]).

%% Artifact of backporting enforce TLS project, MB-48047, to 6.6.4.
%% This is to workaround the cluster_compat_mode check of 7_0.
%% Should git rid off when 6.6.x is unsupported.
-spec is_strict_possible() -> true | false.
is_strict_possible() ->
ns_config:read_key_fast(can_enable_strict_encryption, false).

-spec is_ipv6() -> true | false.
is_ipv6() ->
get_net_family() == inet6.
Expand Down
4 changes: 3 additions & 1 deletion src/netconfig_updater.erl
Expand Up @@ -423,7 +423,9 @@ wait_for_exit(Port, Output) ->

maybe_kill_epmd() ->
NoEpmdFile = path_config:component_path(data, "no_epmd"),
case ?CAN_KILL_EPMD andalso cluster_compat_mode:is_cluster_70() andalso
case ?CAN_KILL_EPMD andalso
(misc:is_strict_possible() orelse
cluster_compat_mode:is_cluster_70()) andalso
(misc:get_afamily_only() orelse misc:disable_non_ssl_ports()) of
true ->
try
Expand Down
1 change: 1 addition & 0 deletions src/ns_cluster.erl
Expand Up @@ -1496,6 +1496,7 @@ perform_actual_join(RemoteNode, NewCookie, ChronicleInfo) ->
ns_ssl_services_setup:update_node_cert_epoch(),

misc:remove_marker(join_marker_path()),
netconfig_updater:maybe_kill_epmd(),

?cluster_debug("Join succeded, starting ns_server_cluster back", []),
case ns_server_cluster_sup:start_ns_server() of
Expand Down

0 comments on commit 6729aae

Please sign in to comment.