fix poller

This commit is contained in:
anlicheng 2025-04-29 15:21:01 +08:00
parent 99cc98e129
commit 089463e11f

View File

@ -148,7 +148,16 @@ handle_info({timeout, _, task_ticker}, State = #state{devices = Devices, status
{noreply, State#state{tasks = Devices}};
?STATUS_PAUSED ->
{noreply, State#state{tasks = []}}
end.
end;
%% task执行超时后才返回
handle_info({ws_response, _Ref, Response}, State = #state{host_id = HostId}) ->
lager:debug("[iot_host_device_poller] host_id: ~p, get ws_response: ~p, after timeout", [HostId, Response]),
{noreply, State};
handle_info(Info, State = #state{host_id = HostId}) ->
lager:debug("[iot_host_device_poller] host_id: ~p, get unknown info: ~p, after timeout", [HostId, Info]),
{noreply, State}.
%% @private
%% @doc This function is called by a gen_server when it is about to