fix: Disable waiting for shards on boot
This commit is contained in:
parent
6aca61d121
commit
7fdcca784d
|
@ -25,13 +25,6 @@
|
||||||
-define(ROUTE_SHARD, route_shard).
|
-define(ROUTE_SHARD, route_shard).
|
||||||
-define(PERSISTENT_SESSION_SHARD, emqx_persistent_session_shard).
|
-define(PERSISTENT_SESSION_SHARD, emqx_persistent_session_shard).
|
||||||
|
|
||||||
-define(BOOT_SHARDS, [
|
|
||||||
?ROUTE_SHARD,
|
|
||||||
?COMMON_SHARD,
|
|
||||||
?SHARED_SUB_SHARD,
|
|
||||||
?PERSISTENT_SESSION_SHARD
|
|
||||||
]).
|
|
||||||
|
|
||||||
%% Banner
|
%% Banner
|
||||||
%%--------------------------------------------------------------------
|
%%--------------------------------------------------------------------
|
||||||
|
|
||||||
|
|
|
@ -44,7 +44,6 @@ start(_Type, _Args) ->
|
||||||
ok = emqx_persistent_session:init_db_backend(),
|
ok = emqx_persistent_session:init_db_backend(),
|
||||||
ok = maybe_start_quicer(),
|
ok = maybe_start_quicer(),
|
||||||
ok = emqx_bpapi:start(),
|
ok = emqx_bpapi:start(),
|
||||||
wait_boot_shards(),
|
|
||||||
ok = emqx_alarm_handler:load(),
|
ok = emqx_alarm_handler:load(),
|
||||||
{ok, Sup} = emqx_sup:start_link(),
|
{ok, Sup} = emqx_sup:start_link(),
|
||||||
ok = maybe_start_listeners(),
|
ok = maybe_start_listeners(),
|
||||||
|
@ -60,9 +59,6 @@ prep_stop(_State) ->
|
||||||
|
|
||||||
stop(_State) -> ok.
|
stop(_State) -> ok.
|
||||||
|
|
||||||
wait_boot_shards() ->
|
|
||||||
ok = mria_rlog:wait_for_shards(?BOOT_SHARDS, infinity).
|
|
||||||
|
|
||||||
%% @doc Call this function to make emqx boot without loading config,
|
%% @doc Call this function to make emqx boot without loading config,
|
||||||
%% in case we want to delegate the config load to a higher level app
|
%% in case we want to delegate the config load to a higher level app
|
||||||
%% which manages emqx app.
|
%% which manages emqx app.
|
||||||
|
|
Loading…
Reference in New Issue