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

[Question] how about the order module throws the exception? #12

Open
hkvincent opened this issue Oct 9, 2021 · 0 comments
Open

[Question] how about the order module throws the exception? #12

hkvincent opened this issue Oct 9, 2021 · 0 comments

Comments

@hkvincent
Copy link

Hi,
I have some confusion after check the code for a few hours, how does the program handle the order module throws the exception and global rollback? since there is no listener for the order module.

happy flow:
order module creates the record first, if there is no exception product and account modules do the same things after the order invokes them.
after the module of the account or the product commits successfully there will have a message sent to RabbitMQ, the account or product will retrieve the transaction ID and commit the transaction if the DistributedTransactionStatus is CONFIRMED

but how about the order module throws an exception? before the exception is thrown order module has called another module to do the transaction, so there is only rollback for local not global?

thanks

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

No branches or pull requests

1 participant