com.solace.spring.cloud.stream.binder.messaging.SolaceHeaders Maven / Gradle / Ivy
Show all versions of spring-cloud-stream-binder-solace Show documentation
package com.solace.spring.cloud.stream.binder.messaging;
import com.solacesystems.jcsmp.Destination;
import com.solacesystems.jcsmp.ReplicationGroupMessageId;
import org.springframework.messaging.Message;
/**
* Solace-defined Spring headers to get/set Solace message properties from/to
* Spring {@link Message Message} headers.
*
* Header Access Control:
* Be aware that each header has an expected usage scenario.
* Using headers outside of their intended access-control scenario is not supported.
*/
public final class SolaceHeaders {
/**
* The prefix used for all headers in this class.
*/
static final String PREFIX = "solace_";
/**
* Acceptable Value Type: {@link String}
* Access: Read/Write
*
* The message ID (a string for an application-specific message identifier).
* This is the {@code JMSMessageID} header field if publishing/consuming to/from JMS.
*/
public static final String APPLICATION_MESSAGE_ID = PREFIX + "applicationMessageId";
/**
* Acceptable Value Type: {@link String}
* Access: Read/Write
*
* The application message type.
* This is the {@code JMSType} header field if publishing/consuming to/from JMS.
*/
public static final String APPLICATION_MESSAGE_TYPE = PREFIX + "applicationMessageType";
/**
* Acceptable Value Type: {@link String}
* Access: Read/Write
*
* The correlation ID.
*/
public static final String CORRELATION_ID = PREFIX + "correlationId";
/**
* Acceptable Value Type: {@link Integer}
* Access: Read
*
* The number of times the message has been delivered.
*/
public static final String DELIVERY_COUNT = PREFIX + "deliveryCount";
/**
* Acceptable Value Type: {@link Destination}
* Access: Read
*
* The destination this message was published to.
*/
public static final String DESTINATION = PREFIX + "destination";
/**
* Acceptable Value Type: {@link Boolean}
* Access: Read
*
* Whether one or more messages have been discarded prior to the current message.
*/
public static final String DISCARD_INDICATION = PREFIX + "discardIndication";
/**
* Acceptable Value Type: {@link Boolean}
* Access: Read/Write
*
* Whether the message is eligible to be moved to a Dead Message Queue.
*/
public static final String DMQ_ELIGIBLE = PREFIX + "dmqEligible";
/**
* Acceptable Value Type: {@link Long}
* Access: Read/Write
*
* The UTC time (in milliseconds, from midnight, January 1, 1970 UTC) when the message is supposed to
* expire.
*/
public static final String EXPIRATION = PREFIX + "expiration";
/**
* Acceptable Value Type: {@link String}
* Access: Read/Write
*
* The HTTP content encoding header value from interaction with an HTTP client.
*/
public static final String HTTP_CONTENT_ENCODING = PREFIX + "httpContentEncoding";
/**
* Acceptable Value Type: {@link Boolean}
* Access: Read/Write
*
* Indicates whether this message is a reply
*/
public static final String IS_REPLY = PREFIX + "isReply";
/**
* Acceptable Value Type: {@link Integer}
* Access: Read/Write
*
* Priority value in the range of 0–255, or -1 if it is not set.
*/
public static final String PRIORITY = PREFIX + "priority";
/**
* Acceptable Value Type: {@link ReplicationGroupMessageId}
* Access: Read
*
* The replication group message ID (Specifies a Replication Group Message ID as a replay start location.).
*/
public static final String REPLICATION_GROUP_MESSAGE_ID = PREFIX + "replicationGroupMessageId";
/**
* Acceptable Value Type: {@link Long}
* Access: Read
*
* The receive timestamp (in milliseconds, from midnight, January 1, 1970 UTC).
*/
public static final String RECEIVE_TIMESTAMP = PREFIX + "receiveTimestamp";
/**
* Acceptable Value Type: {@link Boolean}
* Access: Read
*
* Indicates if the message has been delivered by the broker to the API before.
*/
public static final String REDELIVERED = PREFIX + "redelivered";
/**
* Acceptable Value Type: {@link Destination}
* Access: Read/Write
*
* The replyTo destination for the message.
*/
public static final String REPLY_TO = PREFIX + "replyTo";
/**
* Acceptable Value Type: {@link String}
* Access: Read/Write
*
* The Sender ID for the message.
*/
public static final String SENDER_ID = PREFIX + "senderId";
/**
* Acceptable Value Type: {@link Long}
* Access: Read/Write
*
* The send timestamp (in milliseconds, from midnight, January 1, 1970 UTC).
*/
public static final String SENDER_TIMESTAMP = PREFIX + "senderTimestamp";
/**
* Acceptable Value Type: {@link Long}
* Access: Read/Write
*
* The sequence number.
*/
public static final String SEQUENCE_NUMBER = PREFIX + "sequenceNumber";
/**
* Acceptable Value Type: {@link Long}
* Access: Read/Write
*
* The number of milliseconds before the message is discarded or moved to a Dead Message Queue.
*/
public static final String TIME_TO_LIVE = PREFIX + "timeToLive";
/**
* Acceptable Value Type: {@code byte[]}
* Access: Read/Write
*
* When an application sends a message, it can optionally attach application-specific data along
* with the message, such as user data.
*/
public static final String USER_DATA = PREFIX + "userData";
}