apache / incubator-seata

:fire: Seata is an easy-to-use, high-performance, open source distributed transaction solution.
https://seata.apache.org/
Apache License 2.0
25.33k stars 8.78k forks source link

duplicate items when registering the branch #2716

Open HanKaiqiang opened 4 years ago

HanKaiqiang commented 4 years ago

Ⅰ. Issue Description

lockKeys have the duplicate items, like this: _lockKeys = ci_73_978_njrs:307;ci_73_978_njrs:307,308;ci_73_978_njrs:307,308,309,310,311;ci_73_978_njrs:307,308,309,310;ci_73_978_njrs:307,308,309,310,311,312;ci_73_978_njrs:307,308,309,310,311,312,313,314;ci_73_978_njrs:307,308,309,310,311,312,313;ci_73_799_pjct:14;trigger_tasks_73:167470;ci_73_978_njrs:307,308,309;trigger_task_change_logs73:150222

Ⅱ. Describe what happened

when the @Transactional is under the @GlocalTransactional, and the method is called recursively in many hierarchies

Ⅲ. Describe what you expected to happen

lockKeys should be: _lockKeys = ci_73_978_njrs:309;ci_73_978_njrs:307;ci_73_978_njrs:308;ci_73_978_njrs:314;ci_73_978_njrs:312;trigger_tasks_73:167471;ci_73_978_njrs:313;ci_73_978_njrs:310;ci_73_799_pjct:14;ci_73_978_njrs:311;trigger_task_change_logs73:150223

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

mybatis配置使用 configuration: default-executor-type: reuse

Ⅴ. Anything else we need to know?

Ⅵ. Environment:

slievrly commented 4 years ago

@HanKaiqiang what version is used? This is a bug in the lower version.

HanKaiqiang commented 4 years ago

mybatis-spring-boot-starter: 2.1.0

HanKaiqiang commented 4 years ago

mybatis: mapperLocations: classpath:mapper/*.xml typeAliasesPackage: io.seata.sample.entity configuration-properties: blobType: BLOB boolValue: true prefix: configuration: cache-enabled: false lazy-loading-enabled: false multiple-result-sets-enabled: true use-column-label: true default-statement-timeout: 25000 use-generated-keys: true default-executor-type: reuse call-setters-on-nulls: true map-underscore-to-camel-case: true