Skip to content

[feat][txn] Add TxnID and TransactionCoordinatorClient support to TransactionV5 - #26731

Draft
TomaszGaweda wants to merge 2 commits into
apache:masterfrom
TomaszGaweda:add-txnid-to-TransactionV5
Draft

TomaszGaweda wants to merge 2 commits into
apache:masterfrom
TomaszGaweda:add-txnid-to-TransactionV5

Conversation

@TomaszGaweda

@TomaszGaweda TomaszGaweda commented Sep 28, 2026 •

Copy link
Copy Markdown
Contributor

Motivation

Many streaming engines need to operate on Transaction IDs to deal with exactly-once delivery guarantees.

Previously, in #26646 we've exposed TransactionCoordinatorClient to allow usage in such engines.

This PR does basically the same, but for V5 API, making it ready for streaming engines.

Modifications

Since v5 API does not depend on v4 API, I've copied TxnID and TransactionCoordinatorClient + Exceptions to v5. In PulsarClientV5 I'm returning this wrapped TransactionCoordinatorClient.
TransactionCoordinatorClientV5 just delegates tasks to v4 API, just like most other APIs.

Verifying this change

  • Make sure that the change passes the CI checks.

Every test invoking transactions on V5 API will now test this change.

Does this pull request potentially affect one of the following parts:

If the box was checked, please highlight the changes

  • Dependencies (add or upgrade a dependency)
  • The public API
  • The schema
  • The default values of configurations
  • The threading model
  • The binary protocol
  • The REST endpoints
  • The admin CLI options
  • The metrics
  • Anything that affects deployment

@merlimat merlimat left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

This was intentionally left out from the v5 API to avoid exposing internals.

I think it would be better to have a discussion on what it's needed instead of exposing the transaction client which is not meant to.

@TomaszGaweda

Copy link
Copy Markdown
Contributor Author

@merlimat I am open to discussion, can share stream engine developer PoV :)

@merlimat

Copy link
Copy Markdown
Contributor

@TomaszGaweda Definitely want to hear you PoV! Can you start a thread on the dev@pulsar.apache.org or a new GitHub discussion to explain what "help" do you need from the client API?

Sign up for free to 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.

2 participants