Class Solace.Record

java.lang.Object
org.apache.beam.sdk.io.solace.data.Solace.Record
Enclosing class:
Solace

@DefaultSchema(AutoValueSchema.class) public abstract static class Solace.Record extends Object
Represents a Solace message record with its associated metadata.
  • Constructor Details

    • Record

      public Record()
  • Method Details

    • getMessageId

      @SchemaFieldNumber("0") public abstract String getMessageId()
      Gets the unique identifier of the message, a string for an application-specific message identifier.

      Mapped from XMLMessage.getApplicationMessageId()

      Returns:
      The message ID, or null if not available.
    • getPayload

      @SchemaFieldNumber("1") public abstract byte[] getPayload()
      Gets the payload of the message as a byte array.

      Mapped from BytesXMLMessage.getBytes()

      Returns:
      The message payload.
    • getDestination

      @SchemaFieldNumber("2") public abstract @Nullable Solace.Destination getDestination()
      Gets the destination (topic or queue) to which the message was sent.

      Mapped from XMLMessage.getDestination()

      Returns:
      The destination, or null if not available.
    • getExpiration

      @SchemaFieldNumber("3") public abstract long getExpiration()
      Gets the message expiration time in milliseconds since the Unix epoch.

      A value of 0 indicates the message does not expire.

      Mapped from XMLMessage.getExpiration()

      Returns:
      The expiration timestamp.
    • getPriority

      @SchemaFieldNumber("4") public abstract int getPriority()
      Gets the priority level of the message (0-255, higher is more important). -1 if not set.

      Mapped from XMLMessage.getPriority()

      Returns:
      The message priority.
    • getRedelivered

      @SchemaFieldNumber("5") public abstract boolean getRedelivered()
      Indicates whether the message has been redelivered due to a prior delivery failure.

      Mapped from XMLMessage.getRedelivered()

      Returns:
      True if redelivered, false otherwise.
    • getReplyTo

      @SchemaFieldNumber("6") public abstract @Nullable Solace.Destination getReplyTo()
      Gets the destination to which replies to this message should be sent.

      Mapped from XMLMessage.getReplyTo()

      Returns:
      The reply-to destination, or null if not specified.
    • getReceiveTimestamp

      @SchemaFieldNumber("7") public abstract @Nullable Long getReceiveTimestamp()
      Gets the timestamp (in milliseconds since the Unix epoch) when the message was received by the Solace broker.

      Mapped from XMLMessage.getReceiveTimestamp()

      Returns:
      The timestamp.
    • getSenderTimestamp

      @SchemaFieldNumber("8") public abstract @Nullable Long getSenderTimestamp()
      Gets the timestamp (in milliseconds since the Unix epoch) when the message was sent by the sender. Can be null if not provided.
      Returns:
      The sender timestamp, or null if not available.
    • getSequenceNumber

      @SchemaFieldNumber("9") public abstract @Nullable Long getSequenceNumber()
      Gets the sequence number of the message (if applicable).

      Mapped from XMLMessage.getSequenceNumber()

      Returns:
      The sequence number, or null if not available.
    • getTimeToLive

      @SchemaFieldNumber("10") public abstract long getTimeToLive()
      The number of milliseconds before the message is discarded or moved to Dead Message Queue. A value of 0 means the message will never expire. The default value is 0.

      Mapped from XMLMessage.getTimeToLive()

      Returns:
      The time-to-live value.
    • getReplicationGroupMessageId

      @SchemaFieldNumber("11") public abstract @Nullable String getReplicationGroupMessageId()
      Gets the ID for the message within its replication group (if applicable).

      Mapped from XMLMessage.getReplicationGroupMessageId()

      The ID for a particular message is only guaranteed to be the same for a particular copy of a message on a particular queue or topic endpoint within a replication group. The same message on different queues or topic endpoints within the same replication group may or may not have the same replication group message ID. See more at https://docs.solace.com/API/API-Developer-Guide/Detecting-Duplicate-Mess.htm

      Returns:
      The replication group message ID, or null if not present.
    • getAttachmentBytes

      @SchemaFieldNumber("12") public abstract byte[] getAttachmentBytes()
      Gets the attachment data of the message as a byte array, if any. This might represent files or other binary content associated with the message.

      Mapped from XMLMessage.getAttachmentByteBuffer()

      Returns:
      The attachment data, or an empty byte array if no attachment is present.
    • builder

      public static Solace.Record.Builder builder()