Skip to content
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

Add documentation for Two-phase Commit Transactions #303

Merged

Conversation

brfrn169
Copy link
Collaborator

@brfrn169 brfrn169 commented Sep 10, 2021

This PR adds documentation for Two-phase Commit Transactions. Please take a look!

@brfrn169 brfrn169 self-assigned this Sep 10, 2021
@brfrn169 brfrn169 force-pushed the add-documentation-for-two-phase-commit-transactions branch from 7b7c7f1 to e2e985d Compare September 10, 2021 02:35
@brfrn169 brfrn169 changed the title [DON'T MERGE] Add documentation for Two-phase Commit Transactions Add documentation for Two-phase Commit Transactions Sep 14, 2021
Copy link
Contributor

@feeblefakie feeblefakie left a comment

Choose a reason for hiding this comment

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

Overall looking good. Thank you!
Left minor comments and questions.

docs/two-phase-commit-transactions.md Outdated Show resolved Hide resolved
docs/two-phase-commit-transactions.md Outdated Show resolved Hide resolved

#### Resume the transaction

You can get the transaction object (the `TwoPhaseCommitTransaction` instance) that you have already joined with `TwoPhaseCommitTransactionManager.resume()`:
Copy link
Contributor

Choose a reason for hiding this comment

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

Sorry, I think I'm not fully sure, but a coordinator process also calls resume?
Or, it is only called by a participant process?

Copy link
Collaborator Author

@brfrn169 brfrn169 Sep 16, 2021

Choose a reason for hiding this comment

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

It's supposed to be called only by a participant process. A coordinator can't resume its transaction in the current implementation.

docs/two-phase-commit-transactions.md Outdated Show resolved Hide resolved
docs/two-phase-commit-transactions.md Outdated Show resolved Hide resolved
docs/two-phase-commit-transactions.md Outdated Show resolved Hide resolved
Copy link
Collaborator Author

@brfrn169 brfrn169 left a comment

Choose a reason for hiding this comment

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

Thank you for taking a look at this! I left a reply for your comment. Thanks.


#### Resume the transaction

You can get the transaction object (the `TwoPhaseCommitTransaction` instance) that you have already joined with `TwoPhaseCommitTransactionManager.resume()`:
Copy link
Collaborator Author

@brfrn169 brfrn169 Sep 16, 2021

Choose a reason for hiding this comment

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

It's supposed to be called only by a participant process. A coordinator can't resume its transaction in the current implementation.

Copy link
Contributor

@feeblefakie feeblefakie left a comment

Choose a reason for hiding this comment

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

Thank you!.
Left some comments and suggestions for more clarity and correctness.

docs/two-phase-commit-transactions.md Outdated Show resolved Hide resolved
docs/two-phase-commit-transactions.md Outdated Show resolved Hide resolved
docs/two-phase-commit-transactions.md Outdated Show resolved Hide resolved
docs/two-phase-commit-transactions.md Outdated Show resolved Hide resolved
docs/two-phase-commit-transactions.md Outdated Show resolved Hide resolved
docs/two-phase-commit-transactions.md Outdated Show resolved Hide resolved
docs/two-phase-commit-transactions.md Outdated Show resolved Hide resolved
docs/two-phase-commit-transactions.md Outdated Show resolved Hide resolved
docs/two-phase-commit-transactions.md Outdated Show resolved Hide resolved
docs/two-phase-commit-transactions.md Outdated Show resolved Hide resolved
brfrn169 and others added 2 commits September 17, 2021 08:13
Copy link
Contributor

@feeblefakie feeblefakie left a comment

Choose a reason for hiding this comment

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

LGTM! Thank you!

@feeblefakie feeblefakie merged commit f5433ac into master Sep 17, 2021
@feeblefakie feeblefakie deleted the add-documentation-for-two-phase-commit-transactions branch September 17, 2021 00:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants