tuichenchuxin opened a new issue, #20846:
URL: https://github.com/apache/shardingsphere/issues/20846

   ## Bug Report
   
   ### Which version of ShardingSphere did you use?
   master- edb90c172556fd504cfed7dcd233ef6068f3dc08
   ### Which project did you use? ShardingSphere-JDBC or ShardingSphere-Proxy?
   proxy
   
   ### Steps to reproduce the behavior, such as: SQL to execute, sharding rule 
configuration, when exception occur etc.
   ```
   databaseName: readwrite_splitting_and_shadow
   
   dataSources:
     write_db:
       url: 
jdbc:mysql://mysql.readwrite_splitting_and_shadow.host:3306/write_db?serverTimezone=UTC&useSSL=false&characterEncoding=utf-8
       username: test_user
       password: Test@123
       connectionTimeoutMilliseconds: 30000
       idleTimeoutMilliseconds: 60000
       maxLifetimeMilliseconds: 1800000
       maxPoolSize: 2
       minPoolSize: 2
     write_db_shadow:
       url: 
jdbc:mysql://mysql.readwrite_splitting_and_shadow.host:3306/write_db_shadow?serverTimezone=UTC&useSSL=false&characterEncoding=utf-8
       username: test_user
       password: Test@123
       connectionTimeoutMilliseconds: 30000
       idleTimeoutMilliseconds: 60000
       maxLifetimeMilliseconds: 1800000
       maxPoolSize: 2
       minPoolSize: 2
     read_0:
       url: 
jdbc:mysql://mysql.readwrite_splitting_and_shadow.host:3306/read_0?serverTimezone=UTC&useSSL=false&characterEncoding=utf-8
       username: test_user
       password: Test@123
       connectionTimeoutMilliseconds: 30000
       idleTimeoutMilliseconds: 60000
       maxLifetimeMilliseconds: 1800000
       maxPoolSize: 2
       minPoolSize: 2
     read_1:
       url: 
jdbc:mysql://mysql.readwrite_splitting_and_shadow.host:3306/read_1?serverTimezone=UTC&useSSL=false&characterEncoding=utf-8
       username: test_user
       password: Test@123
       connectionTimeoutMilliseconds: 30000
       idleTimeoutMilliseconds: 60000
       maxLifetimeMilliseconds: 1800000
       maxPoolSize: 2
       minPoolSize: 2
       
   rules:
   - !READWRITE_SPLITTING
     dataSources:
       write-read-ds:
         staticStrategy:
           writeDataSourceName: shadowDataSource
           readDataSourceNames:
             - read_0
             - read_1
   
   - !SHADOW
     dataSources:
       shadowDataSource:
         productionDataSourceName: write_db
         shadowDataSourceName: write_db_shadow
     tables:
       t_shadow:
         dataSourceNames:
           - shadowDataSource
         shadowAlgorithmNames:
           - user-id-insert-match-algorithm
           - user-id-update-match-algorithm
           - user-id-delete-match-algorithm
           - user-id-select-match-algorithm
           - simple-hint-algorithm
     shadowAlgorithms:
       user-id-insert-match-algorithm:
         type: VALUE_MATCH
         props:
           operation: insert
           column: user_id
           value: 0
       user-id-update-match-algorithm:
         type: VALUE_MATCH
         props:
           operation: update
           column: user_id
           value: 0
       user-id-delete-match-algorithm:
         type: VALUE_MATCH
         props:
           operation: delete
           column: user_id
           value: 0
       user-id-select-match-algorithm:
         type: VALUE_MATCH
         props:
           operation: select
           column: user_id
           value: 0
       simple-hint-algorithm:
         type: SIMPLE_HINT
         props:
           foo: bar
   ```
   


-- 
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: 
[email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to