use emqttd:reg_name/2 to replace name/1
This commit is contained in:
parent
5bfd3a784e
commit
1cbdc5e9e4
|
@ -53,10 +53,7 @@ start_link() ->
|
|||
%%%=============================================================================
|
||||
-spec start_link(atom(), pos_integer()) -> {ok, pid()} | ignore | {error, any()}.
|
||||
start_link(Pool, Id) ->
|
||||
gen_server:start_link({local, name(Id)}, ?MODULE, [Pool, Id], []).
|
||||
|
||||
name(Id) ->
|
||||
list_to_atom(lists:concat([?MODULE, "_", integer_to_list(Id)])).
|
||||
gen_server:start_link({local, emqttd:reg_name(?MODULE, Id)}, ?MODULE, [Pool, Id], []).
|
||||
|
||||
%%------------------------------------------------------------------------------
|
||||
%% @doc Submit work to pooler
|
||||
|
|
Loading…
Reference in New Issue