You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by GitBox <gi...@apache.org> on 2020/04/21 10:21:15 UTC

[GitHub] [shardingsphere] jingshanglu opened a new pull request #5250: fix for set transaction of mysql

jingshanglu opened a new pull request #5250:
URL: https://github.com/apache/shardingsphere/pull/5250


   Fixes #4683.
   
   Changes proposed in this pull request:
   - fix for set transaction of mysql
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [shardingsphere] jingshanglu commented on issue #5250: fix for set transaction of mysql

Posted by GitBox <gi...@apache.org>.
jingshanglu commented on issue #5250:
URL: https://github.com/apache/shardingsphere/pull/5250#issuecomment-617607569


   > This PR is clear enough, however, there are two of the concerns,
   > 
   > 1. Is there any handling for other DBs?
   > 2. How about unit test for your PR?
   
   Just for mysql, next subtask will add unit test. @tristaZero 


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [shardingsphere] codecov-io commented on issue #5250: fix for set transaction of mysql

Posted by GitBox <gi...@apache.org>.
codecov-io commented on issue #5250:
URL: https://github.com/apache/shardingsphere/pull/5250#issuecomment-617638131


   # [Codecov](https://codecov.io/gh/apache/shardingsphere/pull/5250?src=pr&el=h1) Report
   > Merging [#5250](https://codecov.io/gh/apache/shardingsphere/pull/5250?src=pr&el=desc) into [master](https://codecov.io/gh/apache/shardingsphere/commit/60796ee158b70fb32d769d064272fd5056e3c554&el=desc) will **decrease** coverage by `0.16%`.
   > The diff coverage is `0.00%`.
   
   [![Impacted file tree graph](https://codecov.io/gh/apache/shardingsphere/pull/5250/graphs/tree.svg?width=650&height=150&src=pr&token=ZvlXpWa7so)](https://codecov.io/gh/apache/shardingsphere/pull/5250?src=pr&el=tree)
   
   ```diff
   @@             Coverage Diff              @@
   ##             master    #5250      +/-   ##
   ============================================
   - Coverage     53.92%   53.76%   -0.17%     
   - Complexity      409      412       +3     
   ============================================
     Files          1165     1165              
     Lines         20675    20778     +103     
     Branches       3737     3754      +17     
   ============================================
   + Hits          11149    11171      +22     
   - Misses         8818     8898      +80     
   - Partials        708      709       +1     
   ```
   
   
   | [Impacted Files](https://codecov.io/gh/apache/shardingsphere/pull/5250?src=pr&el=tree) | Coverage Δ | Complexity Δ | |
   |---|---|---|---|
   | [...sql/parser/mysql/visitor/impl/MySQLTCLVisitor.java](https://codecov.io/gh/apache/shardingsphere/pull/5250/diff?src=pr&el=tree#diff-c2hhcmRpbmdzcGhlcmUtc3FsLXBhcnNlci9zaGFyZGluZ3NwaGVyZS1zcWwtcGFyc2VyLWRpYWxlY3Qvc2hhcmRpbmdzcGhlcmUtc3FsLXBhcnNlci1teXNxbC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvc2hhcmRpbmdzcGhlcmUvc3FsL3BhcnNlci9teXNxbC92aXNpdG9yL2ltcGwvTXlTUUxUQ0xWaXNpdG9yLmphdmE=) | `0.00% <0.00%> (ø)` | `0.00 <0.00> (ø)` | |
   | [...ser/sql/statement/tcl/SetTransactionStatement.java](https://codecov.io/gh/apache/shardingsphere/pull/5250/diff?src=pr&el=tree#diff-c2hhcmRpbmdzcGhlcmUtc3FsLXBhcnNlci9zaGFyZGluZ3NwaGVyZS1zcWwtcGFyc2VyLXN0YXRlbWVudC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvc2hhcmRpbmdzcGhlcmUvc3FsL3BhcnNlci9zcWwvc3RhdGVtZW50L3RjbC9TZXRUcmFuc2FjdGlvblN0YXRlbWVudC5qYXZh) | `0.00% <ø> (ø)` | `0.00 <0.00> (ø)` | |
   | [...e/execute/engine/DefaultSyncTaskExecuteEngine.java](https://codecov.io/gh/apache/shardingsphere/pull/5250/diff?src=pr&el=tree#diff-c2hhcmRpbmctc2NhbGluZy9zaGFyZGluZy1zY2FsaW5nLWNvcmUvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NoYXJkaW5nc3BoZXJlL3NoYXJkaW5nc2NhbGluZy9jb3JlL2V4ZWN1dGUvZW5naW5lL0RlZmF1bHRTeW5jVGFza0V4ZWN1dGVFbmdpbmUuamF2YQ==) | `15.15% <0.00%> (-60.61%)` | `0.00% <0.00%> (ø%)` | |
   | [...mespace/parser/ShardingStrategyBeanDefinition.java](https://codecov.io/gh/apache/shardingsphere/pull/5250/diff?src=pr&el=tree#diff-c2hhcmRpbmctc3ByaW5nL3NoYXJkaW5nLWpkYmMtc3ByaW5nL3NoYXJkaW5nLWpkYmMtc3ByaW5nLW5hbWVzcGFjZS9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvc2hhcmRpbmdzcGhlcmUvc2hhcmRpbmdqZGJjL3NwcmluZy9uYW1lc3BhY2UvcGFyc2VyL1NoYXJkaW5nU3RyYXRlZ3lCZWFuRGVmaW5pdGlvbi5qYXZh) | `70.83% <0.00%> (-20.84%)` | `0.00% <0.00%> (ø%)` | |
   | [...aling/core/execute/executor/SyncExecutorGroup.java](https://codecov.io/gh/apache/shardingsphere/pull/5250/diff?src=pr&el=tree#diff-c2hhcmRpbmctc2NhbGluZy9zaGFyZGluZy1zY2FsaW5nLWNvcmUvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NoYXJkaW5nc3BoZXJlL3NoYXJkaW5nc2NhbGluZy9jb3JlL2V4ZWN1dGUvZXhlY3V0b3IvU3luY0V4ZWN1dG9yR3JvdXAuamF2YQ==) | `0.00% <0.00%> (-15.39%)` | `0.00% <0.00%> (ø%)` | |
   | [...g/core/execute/engine/SyncTaskExecuteCallback.java](https://codecov.io/gh/apache/shardingsphere/pull/5250/diff?src=pr&el=tree#diff-c2hhcmRpbmctc2NhbGluZy9zaGFyZGluZy1zY2FsaW5nLWNvcmUvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NoYXJkaW5nc3BoZXJlL3NoYXJkaW5nc2NhbGluZy9jb3JlL2V4ZWN1dGUvZW5naW5lL1N5bmNUYXNrRXhlY3V0ZUNhbGxiYWNrLmphdmE=) | `0.00% <0.00%> (-14.29%)` | `0.00% <0.00%> (ø%)` | |
   | [...rdingjdbc/jdbc/core/statement/ShadowStatement.java](https://codecov.io/gh/apache/shardingsphere/pull/5250/diff?src=pr&el=tree#diff-c2hhcmRpbmctamRiYy9zaGFyZGluZy1qZGJjLWNvcmUvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NoYXJkaW5nc3BoZXJlL3NoYXJkaW5namRiYy9qZGJjL2NvcmUvc3RhdGVtZW50L1NoYWRvd1N0YXRlbWVudC5qYXZh) | `51.88% <0.00%> (-11.75%)` | `1.00% <0.00%> (+1.00%)` | :arrow_down: |
   | [...re/execute/executor/dumper/AbstractJDBCDumper.java](https://codecov.io/gh/apache/shardingsphere/pull/5250/diff?src=pr&el=tree#diff-c2hhcmRpbmctc2NhbGluZy9zaGFyZGluZy1zY2FsaW5nLWNvcmUvc3JjL21haW4vamF2YS9vcmcvYXBhY2hlL3NoYXJkaW5nc3BoZXJlL3NoYXJkaW5nc2NhbGluZy9jb3JlL2V4ZWN1dGUvZXhlY3V0b3IvZHVtcGVyL0Fic3RyYWN0SkRCQ0R1bXBlci5qYXZh) | `78.94% <0.00%> (-4.39%)` | `0.00% <0.00%> (ø%)` | |
   | [...ication/jdbc/wrapper/StatementExecutorWrapper.java](https://codecov.io/gh/apache/shardingsphere/pull/5250/diff?src=pr&el=tree#diff-c2hhcmRpbmctcHJveHkvc2hhcmRpbmctcHJveHktYmFja2VuZC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvc2hhcmRpbmdzcGhlcmUvc2hhcmRpbmdwcm94eS9iYWNrZW5kL2NvbW11bmljYXRpb24vamRiYy93cmFwcGVyL1N0YXRlbWVudEV4ZWN1dG9yV3JhcHBlci5qYXZh) | `5.66% <0.00%> (-0.73%)` | `0.00% <0.00%> (ø%)` | |
   | [...jdbc/wrapper/PreparedStatementExecutorWrapper.java](https://codecov.io/gh/apache/shardingsphere/pull/5250/diff?src=pr&el=tree#diff-c2hhcmRpbmctcHJveHkvc2hhcmRpbmctcHJveHktYmFja2VuZC9zcmMvbWFpbi9qYXZhL29yZy9hcGFjaGUvc2hhcmRpbmdzcGhlcmUvc2hhcmRpbmdwcm94eS9iYWNrZW5kL2NvbW11bmljYXRpb24vamRiYy93cmFwcGVyL1ByZXBhcmVkU3RhdGVtZW50RXhlY3V0b3JXcmFwcGVyLmphdmE=) | `5.66% <0.00%> (-0.73%)` | `0.00% <0.00%> (ø%)` | |
   | ... and [36 more](https://codecov.io/gh/apache/shardingsphere/pull/5250/diff?src=pr&el=tree-more) | |
   
   ------
   
   [Continue to review full report at Codecov](https://codecov.io/gh/apache/shardingsphere/pull/5250?src=pr&el=continue).
   > **Legend** - [Click here to learn more](https://docs.codecov.io/docs/codecov-delta)
   > `Δ = absolute <relative> (impact)`, `ø = not affected`, `? = missing data`
   > Powered by [Codecov](https://codecov.io/gh/apache/shardingsphere/pull/5250?src=pr&el=footer). Last update [60796ee...a1686bc](https://codecov.io/gh/apache/shardingsphere/pull/5250?src=pr&el=lastupdated). Read the [comment docs](https://docs.codecov.io/docs/pull-request-comments).
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [shardingsphere] coveralls commented on issue #5250: fix for set transaction of mysql

Posted by GitBox <gi...@apache.org>.
coveralls commented on issue #5250:
URL: https://github.com/apache/shardingsphere/pull/5250#issuecomment-617641200


   ## Pull Request Test Coverage Report for [Build 11168](https://coveralls.io/builds/30251677)
   
   * **0** of **14**   **(0.0%)**  changed or added relevant lines in **1** file are covered.
   * **520** unchanged lines in **22** files lost coverage.
   * Overall coverage decreased (**-0.2%**) to **57.238%**
   
   ---
   
   |  Changes Missing Coverage | Covered Lines | Changed/Added Lines | % |
   | :-----|--------------|--------|---: |
   | [shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/impl/MySQLTCLVisitor.java](https://coveralls.io/builds/30251677/source?filename=shardingsphere-sql-parser%2Fshardingsphere-sql-parser-dialect%2Fshardingsphere-sql-parser-mysql%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fshardingsphere%2Fsql%2Fparser%2Fmysql%2Fvisitor%2Fimpl%2FMySQLTCLVisitor.java#L47) | 0 | 14 | 0.0%
   <!-- | **Total:** | **0** | **14** | **0.0%** | -->
   
   |  Files with Coverage Reduction | New Missed Lines | % |
   | :-----|--------------|--: |
   | [sharding-jdbc/sharding-jdbc-core/src/main/java/org/apache/shardingsphere/shardingjdbc/executor/batch/BatchPreparedStatementExecutor.java](https://coveralls.io/builds/30251677/source?filename=sharding-jdbc%2Fsharding-jdbc-core%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fshardingsphere%2Fshardingjdbc%2Fexecutor%2Fbatch%2FBatchPreparedStatementExecutor.java#L136) | 1 | 98.86% |
   | [sharding-scaling/sharding-scaling-core/src/main/java/org/apache/shardingsphere/shardingscaling/core/execute/engine/SyncTaskExecuteCallback.java](https://coveralls.io/builds/30251677/source?filename=sharding-scaling%2Fsharding-scaling-core%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fshardingsphere%2Fshardingscaling%2Fcore%2Fexecute%2Fengine%2FSyncTaskExecuteCallback.java#L31) | 1 | 0% |
   | [sharding-scaling/sharding-scaling-core/src/main/java/org/apache/shardingsphere/shardingscaling/core/synctask/inventory/InventoryDataSyncTaskGroup.java](https://coveralls.io/builds/30251677/source?filename=sharding-scaling%2Fsharding-scaling-core%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fshardingsphere%2Fshardingscaling%2Fcore%2Fsynctask%2Finventory%2FInventoryDataSyncTaskGroup.java#L57) | 1 | 85.71% |
   | [shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/java/org/apache/shardingsphere/sql/parser/mysql/visitor/impl/MySQLTCLVisitor.java](https://coveralls.io/builds/30251677/source?filename=shardingsphere-sql-parser%2Fshardingsphere-sql-parser-dialect%2Fshardingsphere-sql-parser-mysql%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fshardingsphere%2Fsql%2Fparser%2Fmysql%2Fvisitor%2Fimpl%2FMySQLTCLVisitor.java#L66) | 1 | 0% |
   | [shardingsphere-sql-parser/shardingsphere-sql-parser-statement/src/main/java/org/apache/shardingsphere/sql/parser/sql/statement/tcl/SetTransactionStatement.java](https://coveralls.io/builds/30251677/source?filename=shardingsphere-sql-parser%2Fshardingsphere-sql-parser-statement%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fshardingsphere%2Fsql%2Fparser%2Fsql%2Fstatement%2Ftcl%2FSetTransactionStatement.java#L28) | 1 | 0% |
   | [sharding-scaling/sharding-scaling-core/src/main/java/org/apache/shardingsphere/shardingscaling/core/execute/executor/SyncExecutorGroup.java](https://coveralls.io/builds/30251677/source?filename=sharding-scaling%2Fsharding-scaling-core%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fshardingsphere%2Fshardingscaling%2Fcore%2Fexecute%2Fexecutor%2FSyncExecutorGroup.java#L50) | 2 | 0% |
   | [sharding-scaling/sharding-scaling-core/src/main/java/org/apache/shardingsphere/shardingscaling/core/execute/executor/dumper/AbstractJDBCDumper.java](https://coveralls.io/builds/30251677/source?filename=sharding-scaling%2Fsharding-scaling-core%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fshardingsphere%2Fshardingscaling%2Fcore%2Fexecute%2Fexecutor%2Fdumper%2FAbstractJDBCDumper.java#L98) | 3 | 86.84% |
   | [sharding-spring/sharding-jdbc-spring/sharding-jdbc-spring-namespace/src/main/java/org/apache/shardingsphere/shardingjdbc/spring/namespace/parser/ShardingStrategyBeanDefinition.java](https://coveralls.io/builds/30251677/source?filename=sharding-spring%2Fsharding-jdbc-spring%2Fsharding-jdbc-spring-namespace%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fshardingsphere%2Fshardingjdbc%2Fspring%2Fnamespace%2Fparser%2FShardingStrategyBeanDefinition.java#L47) | 5 | 75.0% |
   | [sharding-scaling/sharding-scaling-core/src/main/java/org/apache/shardingsphere/shardingscaling/core/synctask/inventory/InventoryDataSyncTask.java](https://coveralls.io/builds/30251677/source?filename=sharding-scaling%2Fsharding-scaling-core%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fshardingsphere%2Fshardingscaling%2Fcore%2Fsynctask%2Finventory%2FInventoryDataSyncTask.java#L52) | 10 | 83.61% |
   | [sharding-scaling/sharding-scaling-core/src/main/java/org/apache/shardingsphere/shardingscaling/core/execute/engine/ShardingScalingExecuteEngine.java](https://coveralls.io/builds/30251677/source?filename=sharding-scaling%2Fsharding-scaling-core%2Fsrc%2Fmain%2Fjava%2Forg%2Fapache%2Fshardingsphere%2Fshardingscaling%2Fcore%2Fexecute%2Fengine%2FShardingScalingExecuteEngine.java#L56) | 11 | 42.11% |
   <!-- | **Total:** | **520** |  | -->
   
   |  Totals | [![Coverage Status](https://coveralls.io/builds/30251677/badge)](https://coveralls.io/builds/30251677) |
   | :-- | --: |
   | Change from base [Build 11147](https://coveralls.io/builds/30219632): |  -0.2% |
   | Covered Lines: | 11893 |
   | Relevant Lines: | 20778 |
   
   ---
   ##### 💛  - [Coveralls](https://coveralls.io)
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [shardingsphere] jingshanglu edited a comment on issue #5250: fix for set transaction of mysql

Posted by GitBox <gi...@apache.org>.
jingshanglu edited a comment on issue #5250:
URL: https://github.com/apache/shardingsphere/pull/5250#issuecomment-617607569


   > This PR is clear enough, however, there are two of the concerns,
   > 
   > 1. Is there any handling for other DBs?
   > 2. How about unit test for your PR?
   
   Just for mysql, next subtask will add unit test.First make mysql well. @tristaZero 


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [shardingsphere] jingshanglu commented on issue #5250: fix for set transaction of mysql

Posted by GitBox <gi...@apache.org>.
jingshanglu commented on issue #5250:
URL: https://github.com/apache/shardingsphere/pull/5250#issuecomment-617579081


   Well, the key data is placed in SetTransactionStatement, without creating new subclasses to distinguish database types. @tristaZero 


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [shardingsphere] tristaZero commented on issue #5250: fix for set transaction of mysql

Posted by GitBox <gi...@apache.org>.
tristaZero commented on issue #5250:
URL: https://github.com/apache/shardingsphere/pull/5250#issuecomment-617602472


   This PR is clear enough, however, there are two of the concerns,
   1. Is there any handling for other DBs?
   2. How about unit test for your PR?


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [shardingsphere] tristaZero commented on a change in pull request #5250: fix for set transaction of mysql

Posted by GitBox <gi...@apache.org>.
tristaZero commented on a change in pull request #5250:
URL: https://github.com/apache/shardingsphere/pull/5250#discussion_r412643921



##########
File path: shardingsphere-sql-parser/shardingsphere-sql-parser-statement/src/main/java/org/apache/shardingsphere/sql/parser/sql/segment/tcl/dialect/mysql/TransactionCharacteristicSegment.java
##########
@@ -0,0 +1,35 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.shardingsphere.sql.parser.sql.segment.tcl.dialect.mysql;
+
+import lombok.Getter;
+import lombok.Setter;
+import org.apache.shardingsphere.sql.parser.sql.segment.SQLSegment;
+
+@Setter
+@Getter
+public class TransactionCharacteristicSegment implements SQLSegment {

Review comment:
       Final?

##########
File path: shardingsphere-sql-parser/shardingsphere-sql-parser-statement/src/main/java/org/apache/shardingsphere/sql/parser/sql/statement/tcl/dialect/mysql/MysqlSetTransactionStatement.java
##########
@@ -0,0 +1,35 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.shardingsphere.sql.parser.sql.statement.tcl.dialect.mysql;
+
+import lombok.Getter;
+import lombok.Setter;
+import org.apache.shardingsphere.sql.parser.sql.segment.tcl.dialect.mysql.TransactionCharacteristicSegment;
+import org.apache.shardingsphere.sql.parser.sql.statement.tcl.SetTransactionStatement;
+
+import java.util.Collection;
+import java.util.LinkedList;
+
+@Getter
+@Setter
+public final class MysqlSetTransactionStatement extends SetTransactionStatement {

Review comment:
       Do other DBs need similar classes?

##########
File path: shardingsphere-sql-parser/shardingsphere-sql-parser-statement/src/main/java/org/apache/shardingsphere/sql/parser/sql/statement/tcl/SetTransactionStatement.java
##########
@@ -20,5 +20,5 @@
 /**
  * Set transaction statement.
  */
-public final class SetTransactionStatement extends TCLStatement {
+public class SetTransactionStatement extends TCLStatement {

Review comment:
       Is it necessary to create child classes?

##########
File path: shardingsphere-sql-parser/shardingsphere-sql-parser-dialect/shardingsphere-sql-parser-mysql/src/main/antlr4/imports/mysql/TCLStatement.g4
##########
@@ -50,4 +50,16 @@ rollback
 
 savepoint
     : SAVEPOINT
-    ;
\ No newline at end of file
+    ;
+
+transactionCharacteristic_

Review comment:
       If you need to visit `transactionCharacteristic_ `, please rename it to `transactionCharacteristic`.
   It is also necessary to check other rule names. 

##########
File path: sharding-sql-test/src/main/resources/sql/supported/tcl/tcl.xml
##########
@@ -38,7 +38,7 @@
     <sql-case id="rollbackToSavepoint" value="ROLLBACK TO savepoint1" />
     <sql-case id="setGlobalTransaction" value="SET GLOBAL TRANSACTION ISOLATION LEVEL REPEATABLE READ" />
     <sql-case id="setTransactionReadOnly" value="SET TRANSACTION READ ONLY" db-types="MySQL,Oracle,PostgreSQL" />
-    <sql-case id="setTransactionWithName" value="SET TRANSACTION NAME 'comment1'" />
+    <sql-case id="setTransactionWithName" value="SET TRANSACTION NAME 'comment1'" db-types="Oracle,PostgreSQL,SQLServer"/>

Review comment:
       A blank space ahead of `/>` is needed.




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org