TipcMsgGetLbMode get the load balancing mode of a message
msg
message to get load balancing mode from
lb_mode_return
storage for message load balancing mode
TRUE
if the load balancing mode was successfully retrieved from the message, FALSE
otherwise.
If TipcMsgGetLbMode fails, it returns FALSE
and sets the global SmartSockets error number to one of:
TipcMsgGetLbMode gets the load balancing mode of a message. The load balancing mode of a message controls how (or if) the message is load balanced among RTclients subscribed to a load balanced subject. When a message is created, its load balancing mode is initialized to the message type load balancing mode. This allows a default value to easily be set for all messages of a certain type. See TipcMtGetLbMode for more information on message type load balancing modes.
The default load balancing mode is T_IPC_LB_NONE. In this mode, no load balancing is done. The message is delivered to all RTclients subscribing to the subject to which the message is published.
The other load balancing modes are T_IPC_LB_ROUND_ROBIN, T_IPC_LB_WEIGHTED, and T_IPC_LB_SORTED. In these modes, one and only one RTclient in the list of potential receivers receives the message. In ROUND_ROBIN mode, each successive message is sent to the next RTclient in a circular list of RTclients, to distribute the load evenly. WEIGHTED mode sends the message to the most responsive RTclient (as measured by the fewest pending GMD acknowledgments), reasoning that this is also the RTclient with the least load. In SORTED mode, each message is sent to the RTclient whose unique subject name sorts lowest lexicographically.
For more information on load balancing, see the TIBCO SmartSockets User’s Guide.
None
TipcMsgSetLbMode, TipcMtSetLbMode, TipcMtGetLbMode, TipcLbModeToStr
This example retrieves the load balancing mode for a message:
TIBCO SmartSockets™ Application Programming Interface Software Release 6.8, July 2006 Copyright © TIBCO Software Inc. All rights reserved www.tibco.com |