View Source mqtt_sessions_will (mqtt_sessions v2.5.1)

Watchdog process, publishes the will if a session process fails.

Link to this section Summary

Link to this section Functions

Link to this function

code_change(Vsn, State, Extra)

View Source
Link to this function

connected(Pid, Will, SessionExpiry, UserContext)

View Source
-spec connected(pid(), map() | undefined, non_neg_integer(), term()) -> ok.
-spec disconnected(pid()) -> ok.
Link to this function

disconnected(Pid, IsWill, ExpiryInterval)

View Source
-spec disconnected(pid() | undefined, boolean(), non_neg_integer()) -> ok.
Signal the will process that the session got disconnected from the client.
Link to this function

handle_call(Msg, From, State)

View Source
-spec reconnected(pid()) -> ok.
Link to this function

set_user_context(Pid, UserContext)

View Source
-spec set_user_context(pid(), term()) -> ok.
Set a new user context, needed after reauthentication
Link to this function

start_link(Pool, SessionPid)

View Source
-spec start_link(atom(), pid()) -> {ok, pid()}.
-spec stop(pid() | undefined) -> ok.
Sync request to stop the will process
Link to this function

terminate(Reason, State)

View Source