The data structure sizing parameters

Updated: April 19, 2023

These two parameters are used to control various sizes of messaging areas.

The nparts_max parameter controls the size of the dynamically allocated iov member in the resource manager library context block (of type resmgr_context_t, see below). You'd typically adjust this member if you were returning more than a one-part IOV from some of your handling functions. Note that it has no effect on the incoming messages—this is only used on outgoing messages.

The msg_max_size parameter controls how much buffer space the resource manager library should set aside as a receive buffer for the message. The resource manager library will set this value to be at least as big as the header for the biggest message it will be receiving. This ensures that when your handler function gets called, it will be passed the entire header of the message. Note, however, that the data (if any) beyond the current header is not guaranteed to be present in the buffer, even if the msg_max_size parameter is “large enough.”