You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by "liangyepianzhou (via GitHub)" <gi...@apache.org> on 2024/12/15 09:57:42 UTC
[PR] PCIP-3:Pulsar Extended Transaction API Enhancement Proposal [pulsar-java-contrib]
liangyepianzhou opened a new pull request, #11:
URL: https://github.com/apache/pulsar-java-contrib/pull/11
### Motivation
The motivation behind this proposal is to address the issue of duplicate message consumption when using Fail-over subscription mode with cumulative Ack in Pulsar. Despite the use of transactions, achieving exactly-once semantics has been problematic due to the inherent behavior of cumulative Ack. This issue is particularly challenging to resolve within the constraints of the Pulsar main repository for several reasons:
- **Complexity and Longevity**: Fixing this issue without altering the Client API is complex and time-consuming.
- **Confusing API Usage**: The existing transaction APIs in Pulsar are often confusing, with methods like `abort()` and `commit()` appearing synchronous but functioning asynchronously. This leads to incorrect usage patterns, such as needing to call `abort().get()` and `commit().get()` for proper operation.
- **API Modification Challenges**: Modifying the Client API in the Pulsar main repository is difficult due to the uncertainty of whether a new solution will be perfect and the lengthy API update cycle.
### Modifications
The proposed solution involves designing a new transaction API in the contributor repository that wraps the original Transaction API. This approach offers several benefits:
- **Concise Solution**: By wrapping the original API, the problem can be solved in a straightforward and concise manner.
- **Best Practice Reference**: This wrapping serves as a best practice example that does not disrupt existing users' usage while providing a reference solution for those encountering similar issues.
- **Enhanced Usability**: The new API aims to clarify and optimize the transaction methods, making them more intuitive and less prone to misuse, thus improving the overall usability and clarity of transactional operations in Pulsar.
### Verifying this change
- [ ] Make sure that the change passes the CI checks.
*(Please pick either of the following options)*
This change is a trivial rework / code cleanup without any test coverage.
*(or)*
This change is already covered by existing tests, such as *(please describe tests)*.
*(or)*
This change added tests and can be verified as follows:
*(example:)*
- *Added integration tests for end-to-end deployment with large payloads (10MB)*
- *Extended integration test for recovery after broker failure*
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] PCIP-3:Pulsar Extended Transaction API Enhancement Proposal [pulsar-java-contrib]
Posted by "liangyepianzhou (via GitHub)" <gi...@apache.org>.
liangyepianzhou commented on PR #11:
URL: https://github.com/apache/pulsar-java-contrib/pull/11#issuecomment-2543805059
> I think that it is definitively worth to push this initiative to the main repo
I understand your point that the initiative aims to address an existing bug in Pulsar, which indeed warrants consideration for integration into the main repository. However, modifying the public API in the Pulsar main repository is a challenging and lengthy process, and we cannot guarantee that the new API will be flawless and not require further modifications. Therefore, it makes sense to first iterate on the contributor repository, allowing some users to adopt it and solve their issues before considering a merge into the main repository.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] PCIP-3:Pulsar Extended Transaction API Enhancement Proposal [pulsar-java-contrib]
Posted by "AuroraTwinkle (via GitHub)" <gi...@apache.org>.
AuroraTwinkle commented on PR #11:
URL: https://github.com/apache/pulsar-java-contrib/pull/11#issuecomment-2543806121
The CI is failed.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] PCIP-3:Pulsar Extended Transaction API Enhancement Proposal [pulsar-java-contrib]
Posted by "eolivelli (via GitHub)" <gi...@apache.org>.
eolivelli commented on PR #11:
URL: https://github.com/apache/pulsar-java-contrib/pull/11#issuecomment-2543710716
I think that it is definitively worth to push this initiative to the main repo
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] PCIP-3 Pulsar Extended Transaction API Enhancement Proposal [pulsar-java-contrib]
Posted by "AuroraTwinkle (via GitHub)" <gi...@apache.org>.
AuroraTwinkle commented on PR #11:
URL: https://github.com/apache/pulsar-java-contrib/pull/11#issuecomment-2544553264
LGTM
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] PCIP-3:Pulsar Extended Transaction API Enhancement Proposal [pulsar-java-contrib]
Posted by "AuroraTwinkle (via GitHub)" <gi...@apache.org>.
AuroraTwinkle commented on code in PR #11:
URL: https://github.com/apache/pulsar-java-contrib/pull/11#discussion_r1885653931
##########
pulsar-transaction-contrib/pom.xml:
##########
@@ -21,8 +21,51 @@
<artifactId>pulsar-java-contrib</artifactId>
<version>1.0.0-SNAPSHOT</version>
</parent>
- <inceptionYear>2024</inceptionYear>
<artifactId>pulsar-transaction-contrib</artifactId>
+ <dependencies>
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <version>4.13.1</version>
Review Comment:
These dependency versions could be unified into properties and placed in the top-level pom.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] PCIP-3 Pulsar Extended Transaction API Enhancement Proposal [pulsar-java-contrib]
Posted by "liangyepianzhou (via GitHub)" <gi...@apache.org>.
liangyepianzhou merged PR #11:
URL: https://github.com/apache/pulsar-java-contrib/pull/11
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] PCIP-3:Pulsar Extended Transaction API Enhancement Proposal [pulsar-java-contrib]
Posted by "StevenLuMT (via GitHub)" <gi...@apache.org>.
StevenLuMT commented on PR #11:
URL: https://github.com/apache/pulsar-java-contrib/pull/11#issuecomment-2544248136
Change the format of the title. Do you need to change it to:
**[improve][pcip] PCIP-3 Pulsar Extended Transaction API Enhancement Proposal**
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org