| | |
| | | * @return |
| | | */ |
| | | private ShardingTableRuleConfiguration getUserCouponTableRuleConfiguration() { |
| | | ShardingTableRuleConfiguration result = new ShardingTableRuleConfiguration("t_user_coupon", "m$->{0}.t_user_coupon->{1..5}");//50 |
| | | ShardingTableRuleConfiguration result = new ShardingTableRuleConfiguration("t_user_coupon", "m_$->{0}.t_user_coupon->{1..5}");//50 |
| | | result.setTableShardingStrategy(new StandardShardingStrategyConfiguration("userId", "t_user_coupon-inline")); |
| | | result.setKeyGenerateStrategy(new KeyGenerateStrategyConfiguration("id", "t_user_coupon-snowflake")); |
| | | return result; |
| | |
| | | * @return |
| | | */ |
| | | private ShardingTableRuleConfiguration getUserPointsMerchandiseTableRuleConfiguration() { |
| | | ShardingTableRuleConfiguration result = new ShardingTableRuleConfiguration("t_user_points_merchandise", "m$->{0}.t_user_points_merchandise$->{1..5}");//30 |
| | | ShardingTableRuleConfiguration result = new ShardingTableRuleConfiguration("t_user_points_merchandise", "m_$->{0}.t_user_points_merchandise$->{1..5}");//30 |
| | | result.setTableShardingStrategy(new StandardShardingStrategyConfiguration("userId", "t_user_points_merchandise-inline")); |
| | | result.setKeyGenerateStrategy(new KeyGenerateStrategyConfiguration("id", "t_user_points_merchandise-snowflake")); |
| | | return result; |