public interface RawReader
| Modifier and Type | Method and Description |
|---|---|
CompletableFuture<Void> |
acknowledgeCumulativeAsync(org.apache.pulsar.client.api.MessageId messageId,
Map<String,Long> properties)
Acknowledge all messages as read up until messageId.
|
CompletableFuture<Void> |
closeAsync()
Close the raw reader.
|
static CompletableFuture<RawReader> |
create(org.apache.pulsar.client.api.PulsarClient client,
String topic,
String subscription)
Create a raw reader for a topic.
|
CompletableFuture<org.apache.pulsar.client.api.MessageId> |
getLastMessageIdAsync()
Get the last message id available immediately available for reading.
|
String |
getTopic()
Get the topic for the reader.
|
CompletableFuture<Boolean> |
hasMessageAvailableAsync()
Check if there is any message available to read.
|
CompletableFuture<RawMessage> |
readNextAsync()
Read the next raw message for the topic.
|
CompletableFuture<Void> |
seekAsync(org.apache.pulsar.client.api.MessageId messageId)
Seek to a location in the topic.
|
static CompletableFuture<RawReader> create(org.apache.pulsar.client.api.PulsarClient client, String topic, String subscription)
String getTopic()
CompletableFuture<Boolean> hasMessageAvailableAsync()
CompletableFuture<Void> seekAsync(org.apache.pulsar.client.api.MessageId messageId)
messageId - the message ID to seek toCompletableFuture<RawMessage> readNextAsync()
CompletableFuture<Void> acknowledgeCumulativeAsync(org.apache.pulsar.client.api.MessageId messageId, Map<String,Long> properties)
messageId - to cumulatively acknowledge toproperties - a map of properties which will be stored with the acknowledgementCompletableFuture<org.apache.pulsar.client.api.MessageId> getLastMessageIdAsync()
CompletableFuture<Void> closeAsync()
Copyright © 2017–2022 Apache Software Foundation. All rights reserved.