Function rusteron_archive::bindings::aeron_subscription_controlled_poll
source ยท pub unsafe extern "C" fn aeron_subscription_controlled_poll(
subscription: *mut aeron_subscription_t,
handler: aeron_controlled_fragment_handler_t,
clientd: *mut c_void,
fragment_limit: usize,
) -> c_int
Expand description
Poll in a controlled manner the images under the subscription for available message fragments. Control is applied to fragments in the stream. If more fragments can be read on another stream they will even if BREAK or ABORT is returned from the fragment handler.
Each fragment read will be a whole message if it is under MTU length. If larger than MTU then it will come as a series of fragments ordered within a session.
To assemble messages that span multiple fragments then use aeron_controlled_fragment_assembler_t.
@param subscription to poll. @param handler for handling each message fragment as it is read. @param fragment_limit number of message fragments to limit when polling across multiple images. @return the number of fragments received or -1 for error.