Interface PulsarMessage<T>

All Superinterfaces:
ContextAwareMessage<T>, org.eclipse.microprofile.reactive.messaging.Message<T>
All Known Implementing Classes:
PulsarIncomingMessage, PulsarOutgoingMessage

public interface PulsarMessage<T> extends ContextAwareMessage<T>
  • Method Details

    • from

      static <T> PulsarOutgoingMessage<T> from(org.eclipse.microprofile.reactive.messaging.Message<T> message)
      Creates a new outgoing Pulsar message.
      Type Parameters:
      T - the type of the value
      Parameters:
      message - the incoming message
      Returns:
      the new outgoing Pulsar message
    • of

      static <T> PulsarMessage<T> of(T payload)
      Creates a new outgoing Pulsar message.
      Type Parameters:
      T - the type of the value
      Parameters:
      payload - the payload of the message
      Returns:
      the new outgoing Pulsar message
    • of

      static <T> PulsarMessage<T> of(T payload, String key)
      Creates a new outgoing Pulsar message.
      Type Parameters:
      T - the type of the value
      Parameters:
      payload - the payload of the message
      key - the key of the message
      Returns:
      the new outgoing Pulsar message
    • of

      static <T> PulsarMessage<T> of(T payload, byte[] keyBytes)
      Creates a new outgoing Pulsar message.
      Type Parameters:
      T - the type of the value
      Parameters:
      payload - the payload of the message
      keyBytes - the key of the message in bytes
      Returns:
      the new outgoing Pulsar message
    • of

      static <T> PulsarMessage<T> of(T payload, PulsarOutgoingMessageMetadata metadata)
      Creates a new outgoing Pulsar message.
      Type Parameters:
      T - the type of the value
      Parameters:
      payload - the payload of the message
      metadata - the outgoing message metadata
      Returns:
      the new outgoing Pulsar message
    • getKey

      String getKey()
    • getKeyBytes

      byte[] getKeyBytes()
    • hasKey

      boolean hasKey()
    • getOrderingKey

      byte[] getOrderingKey()
    • getProperties

      Map<String,String> getProperties()
    • getEventTime

      long getEventTime()
    • getSequenceId

      long getSequenceId()