Interface SystemTopicClient.Reader<T>

Enclosing interface:
SystemTopicClient<T>

public static interface SystemTopicClient.Reader<T>
Reader for system topic.
  • Method Details

    • readNext

      org.apache.pulsar.client.api.Message<T> readNext() throws org.apache.pulsar.client.api.PulsarClientException
      Read event from system topic.
      Returns:
      pulsar event
      Throws:
      org.apache.pulsar.client.api.PulsarClientException
    • readNextAsync

      CompletableFuture<org.apache.pulsar.client.api.Message<T>> readNextAsync()
      Async read event from system topic.
      Returns:
      pulsar event future
    • hasMoreEvents

      boolean hasMoreEvents() throws org.apache.pulsar.client.api.PulsarClientException
      Check has more events available for the reader.
      Returns:
      true if has remaining events, otherwise false
      Throws:
      org.apache.pulsar.client.api.PulsarClientException
    • hasMoreEventsAsync

      CompletableFuture<Boolean> hasMoreEventsAsync()
      Check has more events available for the reader asynchronously.
      Returns:
      true if has remaining events, otherwise false
    • close

      void close() throws IOException
      Close the system topic reader.
      Throws:
      IOException
    • closeAsync

      CompletableFuture<Void> closeAsync()
      Close the reader of the system topic asynchronously.
    • getSystemTopic

      SystemTopicClient<T> getSystemTopic()
      Get the system topic of the reader.
      Returns:
      system topic