Merge branch 'dev' into dev-hd
This commit is contained in:
commit
f7cf49a17f
|
@ -23,7 +23,7 @@
|
||||||
"plugins/*/"]}.
|
"plugins/*/"]}.
|
||||||
|
|
||||||
{deps, [
|
{deps, [
|
||||||
{gproc, "0.4.*", {git, "git://github.com/uwiger/gproc.git", {branch, "master"}}},
|
{gproc, ".*", {git, "git://github.com/uwiger/gproc.git", {branch, "master"}}},
|
||||||
{lager, ".*", {git, "git://github.com/basho/lager.git", {branch, "master"}}},
|
{lager, ".*", {git, "git://github.com/basho/lager.git", {branch, "master"}}},
|
||||||
{esockd, "2.*", {git, "git://github.com/emqtt/esockd.git", {branch, "master"}}},
|
{esockd, "2.*", {git, "git://github.com/emqtt/esockd.git", {branch, "master"}}},
|
||||||
{mochiweb, ".*", {git, "git://github.com/emqtt/mochiweb.git", {branch, "master"}}}
|
{mochiweb, ".*", {git, "git://github.com/emqtt/mochiweb.git", {branch, "master"}}}
|
||||||
|
|
|
@ -106,15 +106,15 @@ handle_info({stop, duplicate_id, _NewPid}, State=#state{proto_state = ProtoState
|
||||||
[emqttd_protocol:clientid(ProtoState), ConnName]),
|
[emqttd_protocol:clientid(ProtoState), ConnName]),
|
||||||
stop({shutdown, duplicate_id}, State);
|
stop({shutdown, duplicate_id}, State);
|
||||||
|
|
||||||
handle_info({deliver, Message}, #state{proto_state = ProtoState} = State) ->
|
handle_info({deliver, Message}, State = #state{proto_state = ProtoState}) ->
|
||||||
{ok, ProtoState1} = emqttd_protocol:send(Message, ProtoState),
|
{ok, ProtoState1} = emqttd_protocol:send(Message, ProtoState),
|
||||||
{noreply, State#state{proto_state = ProtoState1}};
|
{noreply, State#state{proto_state = ProtoState1}};
|
||||||
|
|
||||||
handle_info({redeliver, {?PUBREL, PacketId}}, #state{proto_state = ProtoState} = State) ->
|
handle_info({redeliver, {?PUBREL, PacketId}}, State = #state{proto_state = ProtoState}) ->
|
||||||
{ok, ProtoState1} = emqttd_protocol:redeliver({?PUBREL, PacketId}, ProtoState),
|
{ok, ProtoState1} = emqttd_protocol:redeliver({?PUBREL, PacketId}, ProtoState),
|
||||||
{noreply, State#state{proto_state = ProtoState1}};
|
{noreply, State#state{proto_state = ProtoState1}};
|
||||||
|
|
||||||
handle_info({subscribe, TopicTable}, #state{proto_state = ProtoState} = State) ->
|
handle_info({subscribe, TopicTable}, State = #state{proto_state = ProtoState}) ->
|
||||||
{ok, ProtoState1} = emqttd_protocol:handle({subscribe, TopicTable}, ProtoState),
|
{ok, ProtoState1} = emqttd_protocol:handle({subscribe, TopicTable}, ProtoState),
|
||||||
{noreply, State#state{proto_state = ProtoState1}};
|
{noreply, State#state{proto_state = ProtoState1}};
|
||||||
|
|
||||||
|
|
|
@ -127,15 +127,15 @@ handle_cast({received, Packet}, State = #client_state{proto_state = ProtoState})
|
||||||
handle_cast(_Msg, State) ->
|
handle_cast(_Msg, State) ->
|
||||||
{noreply, State}.
|
{noreply, State}.
|
||||||
|
|
||||||
handle_info({deliver, Message}, #client_state{proto_state = ProtoState} = State) ->
|
handle_info({deliver, Message}, State = #client_state{proto_state = ProtoState}) ->
|
||||||
{ok, ProtoState1} = emqttd_protocol:send(Message, ProtoState),
|
{ok, ProtoState1} = emqttd_protocol:send(Message, ProtoState),
|
||||||
{noreply, State#client_state{proto_state = ProtoState1}};
|
{noreply, State#client_state{proto_state = ProtoState1}};
|
||||||
|
|
||||||
handle_info({redeliver, {?PUBREL, PacketId}}, #client_state{proto_state = ProtoState} = State) ->
|
handle_info({redeliver, {?PUBREL, PacketId}}, State = #client_state{proto_state = ProtoState}) ->
|
||||||
{ok, ProtoState1} = emqttd_protocol:redeliver({?PUBREL, PacketId}, ProtoState),
|
{ok, ProtoState1} = emqttd_protocol:redeliver({?PUBREL, PacketId}, ProtoState),
|
||||||
{noreply, State#client_state{proto_state = ProtoState1}};
|
{noreply, State#client_state{proto_state = ProtoState1}};
|
||||||
|
|
||||||
handle_info({subscribe, TopicTable}, #client_state{proto_state = ProtoState} = State) ->
|
handle_info({subscribe, TopicTable}, State = #client_state{proto_state = ProtoState}) ->
|
||||||
{ok, ProtoState1} = emqttd_protocol:handle({subscribe, TopicTable}, ProtoState),
|
{ok, ProtoState1} = emqttd_protocol:handle({subscribe, TopicTable}, ProtoState),
|
||||||
{noreply, State#client_state{proto_state = ProtoState1}};
|
{noreply, State#client_state{proto_state = ProtoState1}};
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue