Per-session outbound command queue.
It serializes transport writes and keeps pending commands while the transport connection is unavailable.
Summary
Functions
Returns a specification to start this module under a supervisor.
Enqueues a protocol-critical node ahead of normal application traffic.
Types
@type item() :: {:send_node, term()} | :restart_stream
@type t() :: %ExWapp.Session.OutboundQueue{ conn: pid() | nil, drop_policy: :reject_new | :drop_oldest, flush_batch_size: pos_integer(), flush_tick_ms: pos_integer(), flush_timer: reference() | nil, max_size: pos_integer(), queue: :queue.queue(item()), session: pid(), transport: module() }
Functions
Returns a specification to start this module under a supervisor.
See Supervisor.
@spec clear_conn(pid()) :: :ok
Enqueues a protocol-critical node ahead of normal application traffic.
Stanza ACKs use this path so a reconnect backlog or a burst of outbound messages cannot delay the acknowledgement that keeps the stream healthy.
@spec restart_stream(pid()) :: :ok
@spec start_link(keyword()) :: GenServer.on_start()