recv is:exact
Receive data from the socket. The socket must be in a connected state.
This function may return fewer bytes than specified. If the message is
longer than the specified length, it may be discarded depending on the
type of socket. This function may block until a message arrives.
Considering hardware and network realities, the maximum number of
bytes to receive should be a small power of 2, e.g., 4096.
For TCP sockets, a zero length return value means the peer has closed
its half side of the connection.
Currently, the
recv family is blocked on Windows because a
proper IO manager is not implemented. To use with
timeout on
Windows, use
setSocketOption with
RecvTimeOut as well.
Receive data from the socket. The socket must be in a connected state.
This function may return fewer bytes than specified. If the received
data is longer than the specified length, it may be discarded
depending on the type of socket. This function may block until a
message arrives.
If there is no more data to be received, returns an empty
ByteString.
Read up to a limited number of bytes from a socket.
Returns
Nothing if the remote end closed the connection or
end-of-input was reached. The number of returned bytes might be less
than the specified limit, but it will never
null.
Retrieve a single response from the Memcached server. FIXME: read into
buffer to minimize read syscalls
Receive a message (
MPI_Recv). The MPI datatypeis
determined automatically from the buffer pointer type.
Receives decrypted bytes from the given
Context. Returns
Nothing on EOF.
Up to
16384 decrypted bytes will be received at once.
Efficient network recv
Network recv based on buffer pools