apache / apache/incubator-seata

TCC模式dubbo代理问题

Open
#2,298 0 comments 0 reactions 0 assignees View on GitHub
type: bug
Dominant language
Java
Stars
26k
Forks
8.8k
Avg merge
1d 8h
Merged PRs (30d)
4

Description

- [✔] I have searched the [issues](https://github.com/seata/seata/issues) of this repository and believe that this is not a duplicate.

### Ⅰ. Issue Description
测试发现TCC模式代理了dubbo reference的bean,因此注册分支事务是在TM中进行的而不是RM中。有如下两个问题
1. TC(server)提交或回滚事务分支时,获取RM Channel不能由clientId获取到Channel,只能通过相同resourceId获取到(clientId是TM的clientId)
2. TC刚启动,TC提交或回滚事务分支,可能获取不到RM的Channel(RM每5s执行reconnect)

### Ⅱ. Describe what happened

If there is an exception, please attach the exception trace:

```
Just paste your stack trace here!
```

### Ⅲ. Describe what you expected to happen
TCC模式RM应该由被调用的服务代理,而不是TM代理。想确认一下这个是原来就设计成这样的吗?

### Ⅳ. How to reproduce it (as minimally and precisely as possible)

1. 测试TCC模式,跟踪wrapIfNecessary

### Ⅴ. Anything else we need to know?

### Ⅵ. Environment:

- JDK version : 8
- OS : windows, linux
- Others:

Contributor guide

Open the contributing guide

Research direction

Start at the wrapIfNecessary entry point while tracing TCC mode and the Dubbo reference bean proxying described in the issue. Follow branch registration through the TM and RM, then inspect how TC resolves RM Channels by clientId or resourceId and how reconnect timing affects startup. Done means the intended proxy ownership is confirmed and the two reported channel-resolution cases have a decided resolution.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
distributed-systems
Issue type
Bug
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
20/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.