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 2022/08/13 08:00:18 UTC

[GitHub] [shardingsphere] strongduanmu commented on a diff in pull request #20114: Support distributed transactions across multiple logical database(#19…

strongduanmu commented on code in PR #20114:
URL: https://github.com/apache/shardingsphere/pull/20114#discussion_r945109983


##########
shardingsphere-kernel/shardingsphere-transaction/shardingsphere-transaction-core/src/main/java/org/apache/shardingsphere/transaction/core/ResourceDataSource.java:
##########
@@ -34,8 +35,10 @@ public final class ResourceDataSource {
     private final DataSource dataSource;
     
     public ResourceDataSource(final String originalName, final DataSource dataSource) {
+        final String[] databaseAndDataSourceName = originalName.split("\\.");

Review Comment:
   Please remove final here.



##########
shardingsphere-kernel/shardingsphere-transaction/shardingsphere-transaction-core/src/main/java/org/apache/shardingsphere/transaction/ConnectionTransaction.java:
##########
@@ -46,6 +48,7 @@ public ConnectionTransaction(final String databaseName, final TransactionRule ru
     }
     
     public ConnectionTransaction(final String databaseName, final TransactionType transactionType, final TransactionRule rule) {
+        this.databaseName = databaseName;

Review Comment:
   Should databaseName be extracted from SQL?



-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

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