The goal of this crate is to provide a collection of async sockets which can be used out of the
mio event loop. Currently the crate exposes UDP and TCP sockets:
TcpSock respectively. The socket behavior is very specific for
crates. We aim to make the sockets easy to use and reduce boilerplate code. The sockets buffer
incoming/outgoing data, implement message serialization and encryption, the user of the
stream based sockets don't need to worry about message boundaries, each message has a priority,
Configures socket behavior.
TCP socket which by default is uninitialized. Asynchronous TCP socket wrapper with some specific behavior to our use cases:
Asynchronous UDP socket wrapper with some specific behavior to our use cases:
Simplifies decryption by holding the necessary context - keys to decrypt data. Allows "null" decryption where data is only deserialized. See: null object pattern.
Simplifies encryption by holding the necessary context - encryption keys. Allows "null" encryption where data is only serialized. See: null object pattern.
Common module specific error
Maximum age of a message waiting to be sent. If a message is older, the queue is dropped.
Don't allow packets bigger than this value.
Minimum priority for droppable messages. Messages with lower values will never be dropped.
Priority of a message to be sent by Crust. A lower value means a higher priority, so Priority 0
is the highest one. Low-priority messages will be preempted if need be to allow higher priority
messages through. Messages with a value