Class DefaultMessage

java.lang.Object
io.gravitee.gateway.reactive.api.message.AbstractMessage
io.gravitee.gateway.reactive.api.message.DefaultMessage
All Implemented Interfaces:
Message, TracingMessage

public class DefaultMessage extends AbstractMessage implements TracingMessage
  • Method Details

    • headers

      public HttpHeaders headers()
      Description copied from interface: Message
      Get the headers of the message.
      Specified by:
      headers in interface Message
      Returns:
      a read-write map of headers.
    • content

      public DefaultMessage content(Buffer content)
      Description copied from interface: Message
      Set the content of the message.
      Specified by:
      content in interface Message
      Parameters:
      content - the buffer representing the content of the message.
      Returns:
      reference to itself for easily chain calls.
    • content

      public DefaultMessage content(String content)
      Description copied from interface: Message
      Set the content of the message.
      Specified by:
      content in interface Message
      Parameters:
      content - the buffer representing the content of the message.
      Returns:
      reference to itself for easily chain calls.
    • ack

      public void ack()
      Description copied from interface: Message
      MUST be called to acknowledge this message when it has been well-processed.
      Specified by:
      ack in interface Message
    • doOnEnd

      public DefaultMessage doOnEnd(Runnable runnable)
      Description copied from interface: TracingMessage
      Behavior to apply when the underlying span will be ended.
      Specified by:
      doOnEnd in interface TracingMessage
    • end

      public void end()
      Description copied from interface: TracingMessage
      Run the end behavior defined by TracingMessage.doOnEnd(Runnable)
      Specified by:
      end in interface TracingMessage
    • tracingAttributes

      public Map<String,String> tracingAttributes()
      Description copied from interface: TracingMessage
      Return tracing attributes based on Semantic Conventions for Messaging
      Specified by:
      tracingAttributes in interface TracingMessage
      Returns:
      map of tracing attributes
    • addTracingAttribute

      public void addTracingAttribute(String key, String value)
      Description copied from interface: TracingMessage
      Allow to add extra tracing attribute used to trace this message
      Specified by:
      addTracingAttribute in interface TracingMessage
      Parameters:
      key - the key of the span attribute
      value - the value associated
    • builder

      public static DefaultMessage.DefaultMessageBuilder builder()