-
Notifications
You must be signed in to change notification settings - Fork 3.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[fix][txn] fix NPE of TransactionMetaStoreHandler #15840
Merged
codelipenghui
merged 3 commits into
apache:master
from
congbobo184:congbobo184_txn_client_cnx_null_problem
Jun 9, 2022
Merged
[fix][txn] fix NPE of TransactionMetaStoreHandler #15840
codelipenghui
merged 3 commits into
apache:master
from
congbobo184:congbobo184_txn_client_cnx_null_problem
Jun 9, 2022
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
congbobo184
added
type/bug
The PR fixed a bug or issue reported a bug
area/transaction
doc-not-needed
Your PR changes do not impact docs
release/2.9.3
release/2.10.1
labels
May 30, 2022
congbobo184
requested review from
Technoboy-,
eolivelli,
codelipenghui,
gaoran10 and
mattisonchao
May 30, 2022 10:37
/pulsarbot run-failure-checks |
…ent_cnx_null_problem
mattisonchao
approved these changes
Jun 6, 2022
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM,
codelipenghui
approved these changes
Jun 9, 2022
codelipenghui
changed the title
[fix][txn] Transaction metadata client cnx is null
[fix][txn] fix NPE of TransactionMetaStoreHandler
Jun 9, 2022
codelipenghui
pushed a commit
that referenced
this pull request
Jun 10, 2022
(cherry picked from commit f9b0912)
codelipenghui
pushed a commit
that referenced
this pull request
Jun 12, 2022
(cherry picked from commit f9b0912)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
area/transaction
cherry-picked/branch-2.9
Archived: 2.9 is end of life
cherry-picked/branch-2.10
doc-not-needed
Your PR changes do not impact docs
release/2.9.3
release/2.10.1
type/bug
The PR fixed a bug or issue reported a bug
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Motivation
fix transactionMetadataStoreHandle cnx is null.
pulsar/pulsar-client/src/main/java/org/apache/pulsar/client/impl/TransactionMetaStoreHandler.java
Lines 134 to 154 in b13d15c
because
pulsar/pulsar-client/src/main/java/org/apache/pulsar/client/impl/TransactionMetaStoreHandler.java
Line 142 in b13d15c
is the async method, set cnx, and change to ready state is not an atomic operation.
pulsar/pulsar-client/src/main/java/org/apache/pulsar/client/impl/ConnectionHandler.java
Line 101 in 29308e4
Modifications
fix race condition
Does this pull request potentially affect one of the following parts:
If
yes
was chosen, please highlight the changesDocumentation