Skip to content

feat(asyncio): add Reader API - #309

Merged
BewareMyPower merged 4 commits into
apache:mainfrom
BewareMyPower:bewaremypower/async-reader
Jun 29, 2026
Merged

feat(asyncio): add Reader API#309
BewareMyPower merged 4 commits into
apache:mainfrom
BewareMyPower:bewaremypower/async-reader

Conversation

@BewareMyPower

Copy link
Copy Markdown
Contributor

No description provided.

@BewareMyPowerBewareMyPower self-assigned this Jun 17, 2026
@BewareMyPowerBewareMyPower added this to the 3.13.0 milestone Jun 17, 2026
@BewareMyPower
BewareMyPower marked this pull request as draft June 17, 2026 08:02
@BewareMyPower
BewareMyPower marked this pull request as ready for review June 18, 2026 08:21
@RobertIndie
RobertIndie requested a review from CopilotJune 23, 2026 07:58

CopilotAI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Note

Copilot couldn't run its full agentic review because no GitHub Actions runner was available. Make sure your repository has a runner available to run Copilot's review, or add a copilot-setup-steps.yml file specifying one with the runs-on attribute. See the docs for more details.

Adds an asyncio-compatible Reader API to the Python Pulsar client, including C++ binding support and new integration tests.

Changes:

  • Introduced pulsar.asyncio.Reader with async read_next, seek, has_message_available, and close.
  • Added pybind11 C++ exports for Reader async methods and Client async reader creation.
  • Added asyncio test coverage for basic reader flows (start positions, seek, message availability, auth failure).

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 6 comments.

FileDescription
tests/asyncio_test.pyAdds asyncio integration tests validating new Reader behaviors (read, seek, has-message, auth).
src/reader.ccExposes Reader async operations (read_next_async, seek_async, etc.) via pybind11 with GIL release.
src/client.ccExposes async reader creation APIs (create_reader_async, create_reader_async_v2) for asyncio wrapper use.
pulsar/asyncio.pyImplements the new Reader wrapper and Client.create_reader() coroutine.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment threadpulsar/asyncio.py Outdated
Comment threadpulsar/asyncio.py
Comment threadsrc/reader.cc
Comment threadsrc/reader.cc
Comment threadtests/asyncio_test.py
Comment threadtests/asyncio_test.py
Comment threadpulsar/asyncio.py Outdated
@BewareMyPower
BewareMyPower merged commit 268fe24 into apache:mainJun 29, 2026
11 checks passed
@BewareMyPower
BewareMyPower deleted the bewaremypower/async-reader branch June 29, 2026 02:25
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

@BewareMyPower@RobertIndie