mochiweb -> cowboy

This commit is contained in:
turtled 2018-08-09 15:19:45 +08:00
parent 09b5535260
commit d516b8c241
2 changed files with 3 additions and 3 deletions

View File

@ -166,8 +166,8 @@ shutdown() ->
shutdown(Reason) ->
emqx_logger:error("emqx shutdown for ~s", [Reason]),
emqx_plugins:unload(),
lists:foreach(fun application:stop/1, [emqx, ekka, mochiweb, esockd, gproc]).
lists:foreach(fun application:stop/1, [emqx, ekka, cowboy, esockd, gproc]).
reboot() ->
lists:foreach(fun application:start/1, [gproc, esockd, mochiweb, ekka, emqx]).
lists:foreach(fun application:start/1, [gproc, esockd, cowboy, ekka, emqx]).

View File

@ -27,7 +27,7 @@ start_link() ->
supervisor:start_link({local, ?MODULE}, ?MODULE, []).
%% @doc Start a MQTT/WebSocket Connection.
-spec(start_connection(pid(), mochiweb_request:request()) -> {ok, pid()}).
-spec(start_connection(pid(), cowboy_req:req()) -> {ok, pid()}).
start_connection(WsPid, Req) ->
supervisor:start_child(?MODULE, [WsPid, Req]).