class documentation
The Pulsar topic reader, used to read messages from a topic.
| Method | __init__ |
Create the reader. Users should not call this constructor directly. Instead, create the reader via Client.create_reader. |
| Async Method | close |
Close the reader asynchronously. |
| Async Method | has |
Check if there is any message available to read from the current position. |
| Method | is |
Check if the reader is connected or not. |
| Async Method | read |
Read a single message asynchronously. |
| Async Method | seek |
Reset this reader to a specific message id or publish timestamp asynchronously. |
| Method | topic |
Return the topic this reader is reading from. |
| Instance Variable | _reader |
Undocumented |
| Instance Variable | _schema |
Undocumented |
Create the reader. Users should not call this constructor directly. Instead, create the reader via Client.create_reader.
| Parameters | |
reader:_pulsar.Reader | The underlying Reader object from the C extension. |
schema:pulsar.schema.Schema | The schema of the data that will be received by this reader. |
Read a single message asynchronously.
| Returns | |
pulsar.Message | The message received. |
| Raises | |
PulsarException | |
Reset this reader to a specific message id or publish timestamp asynchronously.
| Parameters | |
messageid:MessageId or int | The message id for seek, OR an integer event time (timestamp) to seek to. |
| Raises | |
PulsarException | |