tibemsMsgProducer_Send
Function
C Declaration
tibems_status tibemsMsgProducer_Send( tibemsMsgProducer msgProducer, tibemsMsg message ); tibems_status tibemsMsgProducer_SendEx( tibemsMsgProducer msgProducer, tibemsMsg message, tibems_int deliveryMode, tibems_int priority, tibems_long timeToLive ); tibems_status tibemsMsgProducer_SendToDestination( tibemsMsgProducer msgProducer, tibemsDestination destination, tibemsMsg message ); tibems_status tibemsMsgProducer_SendToDestinationEx( tibemsMsgProducer msgProducer, tibemsDestination destination, tibemsMsg message, tibemsDeliveryMode deliveryMode, tibems_int priority, tibems_long timeToLive );
COBOL Call
CALL "tibemsMsgProducer_Send" USING BY VALUE msgProducer, BY VALUE message, RETURNING tibems-status END-CALL. CALL "tibemsMsgProducer_SendEx" USING BY VALUE msgProducer, BY VALUE message, BY VALUE deliveryMode, BY VALUE priority, BY VALUE timeToLive, RETURNING tibems-status END-CALL. CALL "tibemsMsgProducer_SendToDestination" USING BY VALUE msgProducer, BY VALUE destination, BY VALUE message, RETURNING tibems-status END-CALL. CALL "tibemsMsgProducer_SendToDestinationEx" USING BY VALUE msgProducer, BY VALUE destination, BY VALUE message, BY VALUE deliveryMode, BY VALUE priority, BY VALUE timeToLive, RETURNING tibems-status END-CALL.
Parameters
Parameter | Description |
---|---|
msgProducer | Send a message through this producer object. |
destination | Send the message to this destination (queue or topic).
Other send calls send the message to the producer’s default destination. When the producer does not specify a default, the send call must supply this parameter. |
message | Send this message object. |
deliveryMode | Send the message with this delivery mode.
This argument is an enumerated value (see tibemsDeliveryMode). Other send calls send the message with the producer’s default delivery mode. |
priority | Send the message with this priority.
Priority affects the order in which the server delivers messages to consumers (higher values first). The JMS specification defines ten levels of priority value, from zero (lowest priority) to 9 (highest priority). The specification suggests that clients consider 0–4 as gradations of normal priority, and priorities 5–9 as gradations of expedited priority. Other send calls send the message with the producer’s default priority. |
timeToLive | Use this value (in milliseconds) to compute the message expiration.
Other send calls use the producer’s default value to compute expiration. Whenever your application uses non-zero values for message expiration or time-to-live, you must ensure that clocks are synchronized among all the host computers that send and receive messages. Synchronize clocks to a tolerance that is a very small fraction of the smallest or time-to-live. |