API Reference barytherium v0.2.0
modules
Modules
Barytherium is an Elixir STOMP client, and a replacement for Mammoth/Elephant, with the aim of improving performance, particularly for high-volume binary message queues (such as National Rail Enquiries' Darwin push port)
This module serves as a more-or-less self-contained example of how to use Barytherium in your own project.
Representation of a STOMP frame.
Macros for defining parse parse functions for commands, for both LF and CRLF versions.
ValueEncoding functions for STOMP. This is handled automatically by functions in Barytherium.Frame
Responsible for coordinating Sender and Receiver. Note that when started, this will immediately (and asynchronously) try to connect to the given host and port.
The Receiver
is designed to work with Barytherium.Network
to move frames from
an already opened socket, reporting status back to an instance of Barytherium.Network
,
and frames back to a listener process, including a Barytherium.Network.Sender
pid when
it does so. This is implemented as a loop with no message receiving capabilities, outside
of the reply made to a call to Barytherium.Network
to report the CONNECTED frame, for
which it receives back a tuple which sets out the heartbeats. The loop ends on most error
conditions, including those which can be created elsewhere (e.g. if it gets
{:error, :closed}
when calling recv).
Genserver for sending frames, see Barytherium.Network.Sender.write/2