CrazyFz commented on issue #8638:
URL: https://github.com/apache/shardingsphere/issues/8638#issuecomment-745732746
> it is your configurations error.
>
> `Properties tableShardingAlgorithmrProps = new Properties();
> tableShardingAlgorithmrProps.setProperty(
> "algorithm-expression", "ssuser_${user_id}");
> shardingRuleConfig.getShardingAlgorithms().put("tableShardingAlgorithm",
> new ShardingSphereAlgorithmConfiguration("INLINE",
> tableShardingAlgorithmrProps));
>
> Properties tableShardingAlgorithmrProps2 = new Properties();
> tableShardingAlgorithmrProps2.setProperty(
> "algorithm-expression", "gateway_${user_id}");
>
> shardingRuleConfig.getShardingAlgorithms().put("tableShardingAlgorithm",
> new ShardingSphereAlgorithmConfiguration("INLINE",
> tableShardingAlgorithmrProps2));`
> when you exetuted shardingRuleConfig.getShardingAlgorithms(), you put the
same key 'tableShardingAlgorithm' into map, it was replace of new value 'new
ShardingSphereAlgorithmConfiguration("INLINE", tableShardingAlgorithmrProps2)';
Thanks , you are right
----------------------------------------------------------------
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:
[email protected]