- dble version:
- preconditions :
no
- configs:
schema.xml
<table name="xa_test" dataNode="dn1,dn2" rule="sharding-by-mod2" primaryKey="ID"/>
rule.xml
<tableRule name="sharding-by-mod2">
<rule>
<columns>id</columns>
<algorithm>hashmod2</algorithm>
</rule>
</tableRule>
<function name="hashmod2" class="Hash">
<property name="partitionCount">2</property>
<property name="partitionLength">1</property>
</function>
server.xml
- steps:
step1. edit com.actiontech.dble.backend.mysql.nio.MySQLConnection#synAndDoExecuteMultiNode

add following code
xaCmd = xaCmd.replace("'", "\\'");
xaCmd = "MOCK ERROR '" + xaCmd + "'";
step2. execute sql
set xa = 1;
delete from xa_test;
-
expect result:
- sql execution returns the exepcted syntax error response
-
real result:
- cmd hang!!!

-
supplements:
1.
/label ~BUG