SwimEx. Transport. UDP
(SwimEx v0.1.0)
View Source
UDP transport using a single dual-stack (IPv4+IPv6) socket.
Opens an :inet6 socket with ipv6_v6only: false so it accepts
both IPv4 and IPv6 traffic on one port. On Linux this is the
default; on platforms where dual-stack is unavailable the socket
falls back to IPv4-only.
Summary
Functions
Returns a specification to start this module under a supervisor.
Closes the transport socket.
Sends data to a node.
Sets the receiver process for incoming SWIM packets.
Starts the UDP transport.
Functions
Returns a specification to start this module under a supervisor.
See Supervisor.
@spec close(GenServer.server()) :: :ok
Closes the transport socket.
@spec send(GenServer.server(), SwimEx.Transport.node_id(), binary()) :: :ok
Sends data to a node.
@spec set_receiver(GenServer.server(), pid()) :: :ok
Sets the receiver process for incoming SWIM packets.
@spec start_link(keyword()) :: GenServer.on_start()
Starts the UDP transport.