@Internal public class MessageProducerUtils extends java.lang.Object
| Constructor and Description | 
|---|
| MessageProducerUtils() | 
| Modifier and Type | Method and Description | 
|---|---|
| static BytesXMLMessage | createBytesXMLMessage(Solace.Record record,
                     boolean useCorrelationKeyLatency,
                     DeliveryMode deliveryMode)Create a  BytesXMLMessageto be published in Solace. | 
| static JCSMPSendMultipleEntry[] | createJCSMPSendMultipleEntry(java.util.List<Solace.Record> records,
                            boolean useCorrelationKeyLatency,
                            SerializableFunction<Solace.Record,Destination> destinationFn,
                            DeliveryMode deliveryMode)Create a  JCSMPSendMultipleEntryarray to be published in Solace. | 
public static BytesXMLMessage createBytesXMLMessage(Solace.Record record, boolean useCorrelationKeyLatency, DeliveryMode deliveryMode)
BytesXMLMessage to be published in Solace.record - The record to be published.useCorrelationKeyLatency - Whether to use a complex key for tracking latency.deliveryMode - The DeliveryMode used to publish the message.BytesXMLMessage that can be sent to Solace "as is".public static JCSMPSendMultipleEntry[] createJCSMPSendMultipleEntry(java.util.List<Solace.Record> records, boolean useCorrelationKeyLatency, SerializableFunction<Solace.Record,Destination> destinationFn, DeliveryMode deliveryMode)
JCSMPSendMultipleEntry array to be published in Solace. This can be used with
 `sendMultiple` to send all the messages in a single API call.
 The size of the list cannot be larger than 50 messages. This is a hard limit enforced by the Solace API.
records - A List of records to be publisheduseCorrelationKeyLatency - Whether to use a complex key for tracking latency.destinationFn - A function that maps every record to its destination.deliveryMode - The DeliveryMode used to publish the message.JCSMPSendMultipleEntry array that can be sent to Solace "as is".