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

feat:增加多数据源事务同步机制&多数据源事务单元测试 #581

Merged
merged 5 commits into from
Oct 23, 2023
Merged

Conversation

ZPZP1
Copy link
Contributor

@ZPZP1 ZPZP1 commented Oct 21, 2023

What kind of change does this PR introduce? (check at least one)

  • Bugfix
  • [ √] Feature
  • Code style
  • Refactor
  • Doc
  • Other, please describe:

The description of the PR:
增加多数据源事务同步机制,可以使用@DsTxEventListener进行事务生命周期同步处理或者通过编程式注册事务同步信息

TransactionContext.registerSynchronization(new TransactionSynchronization() {
            @Override
            public void beforeCommit(boolean readOnly) {
             
            }

            @Override
            public void beforeCompletion() {
              
            }

            @Override
            public void afterCommit() {
              
            }

            @Override
            public void afterCompletion(int status) {
               
            }
        });

Other information:
#577

@ZPZP1
Copy link
Contributor Author

ZPZP1 commented Oct 22, 2023

下午重新写一下单元测试

@ZPZP1 ZPZP1 changed the title feat:增加多数据源事务同步机制 feat:增加多数据源事务同步机制&多数据源事务单元测试 Oct 22, 2023
@ZPZP1
Copy link
Contributor Author

ZPZP1 commented Oct 22, 2023

完事,@huayanYu 有时间review一下

@huayanYu huayanYu merged commit b4a0ee2 into baomidou:master Oct 23, 2023
4 checks passed
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.

None yet

2 participants