CrackerSuperior opened a new issue #12754:
URL: https://github.com/apache/shardingsphere/issues/12754


   In the official example, I am a little confused, the configuration file is 
as follows:
   ``` yaml
   schemaName: logic_db
   
   rules:
   - !SHARDING
     tables:
       t_order:
         actualDataNodes: jdbc_${0..1}.t_order_${0..1}
       t_order_item:
         actualDataNodes: jdbc_${0..1}.t_order_item_${0..1}
         keyGenerateStrategy:
           column: item_id
           keyGeneratorName: increment
       t_config:
         actualDataNodes: jdbc_${0..1}.t_config
       t_user:
         actualDataNodes: jdbc_0.t_user_${0..1}
         tableStrategy:
           standard:
             shardingColumn: id
             shardingAlgorithmName: table_inline
         keyGenerateStrategy:
           column: id
           keyGeneratorName: reset_increment
     autoTables:
       t_order_auto:
         actualDataSources: jdbc_0, jdbc_1
         shardingStrategy:
           standard:
             shardingColumn: order_id
             shardingAlgorithmName: mod
       t_order_item_auto:
         shardingStrategy:
           standard:
             shardingColumn: order_id
             shardingAlgorithmName: mod
     bindingTables:
       - t_order,t_order_item
     broadcastTables:
       - t_config
     defaultTableStrategy:
       standard:
         shardingColumn: order_id
         shardingAlgorithmName: standard_test
     defaultDatabaseStrategy:
       standard:
         shardingColumn: user_id
         shardingAlgorithmName: standard_test
     
     shardingAlgorithms:
       standard_test:
           type: STANDARD_TEST
       table_inline:
         type: INLINE
         props:
           algorithm-expression: t_user_${id % 2}
       mod:
         type: MOD
         props:
           sharding-count: 2
     
     keyGenerators:
       increment:
         type: INCREMENT
       reset_increment:
         type: RESET_INCREMENT
   ```
   I don't understand how this t_order uses t_order_auto. Does it just use name 
recognition?


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