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>
  • Field Summary

    Fields inherited from interface org.eclipse.microprofile.reactive.messaging.Message

    EMPTY_ACK, EMPTY_NACK, LOGGER
  • Method Summary

    Modifier and Type
    Method
    Description
    static <T> PulsarOutgoingMessage<T>
    from(org.eclipse.microprofile.reactive.messaging.Message<T> message)
    Creates a new outgoing Pulsar message.
    long
     
     
    byte[]
     
    byte[]
     
     
    long
     
    boolean
     
    static <T> PulsarMessage<T>
    of(T payload)
    Creates a new outgoing Pulsar message.
    static <T> PulsarMessage<T>
    of(T payload, byte[] keyBytes)
    Creates a new outgoing Pulsar message.
    static <T> PulsarMessage<T>
    of(T payload, PulsarOutgoingMessageMetadata metadata)
    Creates a new outgoing Pulsar message.
    static <T> PulsarMessage<T>
    of(T payload, String key)
    Creates a new outgoing Pulsar message.

    Methods inherited from interface io.smallrye.reactive.messaging.providers.locals.ContextAwareMessage

    getContextMetadata, runOnMessageContext

    Methods inherited from interface org.eclipse.microprofile.reactive.messaging.Message

    ack, ack, addMetadata, getAck, getAckWithMetadata, getMetadata, getMetadata, getNack, getNackWithMetadata, getPayload, nack, nack, thenApply, unwrap, withAck, withAckWithMetadata, withMetadata, withMetadata, withNack, withNackWithMetadata, withPayload
  • 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()