Mojentic.Realtime.MintTransport (Mojentic v1.5.0)

Copy Markdown View Source

WebSocket transport backed by Mint.WebSocket.

Opens a TLS connection, upgrades to WebSocket, and pumps frames in a GenServer. Inbound text frames are JSON-decoded and forwarded to the subscribed process as {:realtime_message, map} messages. Connection-level events arrive as {:realtime_close, reason} and {:realtime_error, reason}.

Outbound payloads are JSON-encoded and sent as a single text frame via send/2.

Production implementation of Mojentic.Realtime.Transport.

Summary

Functions

Returns a specification to start this module under a supervisor.

Functions

child_spec(init_arg)

Returns a specification to start this module under a supervisor.

See Supervisor.