Class ReactorReactivePublisher

java.lang.Object
io.micronaut.nats.reactive.ReactorReactivePublisher
All Implemented Interfaces:
ReactivePublisher

@Internal @EachBean(io.nats.client.Connection.class) public class ReactorReactivePublisher extends Object implements ReactivePublisher
Author:
jgrimm
  • Constructor Summary

    Constructors
    Constructor
    Description
    ReactorReactivePublisher(io.nats.client.Connection connection)
    Constructor.
  • Method Summary

    Modifier and Type
    Method
    Description
    org.reactivestreams.Publisher<Void>
    publish(io.nats.client.Message message)
    Publish the message with the provided arguments and return a reactive type that completes successfully when the message is published.
    org.reactivestreams.Publisher<io.nats.client.Message>
    publishAndReply(io.nats.client.Message message)
    Publish the message with the provided arguments and return a reactive type that completes successfully when the reply is received from the reply to queue.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • ReactorReactivePublisher

      public ReactorReactivePublisher(@Parameter io.nats.client.Connection connection)
      Constructor.
      Parameters:
      connection - The given connection
  • Method Details

    • publish

      public org.reactivestreams.Publisher<Void> publish(io.nats.client.Message message)
      Description copied from interface: ReactivePublisher
      Publish the message with the provided arguments and return a reactive type that completes successfully when the message is published.
      Specified by:
      publish in interface ReactivePublisher
      Parameters:
      message - The message to publish
      Returns:
      the publisher
    • publishAndReply

      public org.reactivestreams.Publisher<io.nats.client.Message> publishAndReply(io.nats.client.Message message)
      Description copied from interface: ReactivePublisher
      Publish the message with the provided arguments and return a reactive type that completes successfully when the reply is received from the reply to queue.
      Specified by:
      publishAndReply in interface ReactivePublisher
      Parameters:
      message - The message to publish
      Returns:
      The publisher of the received reply