use of io.shardingjdbc.core.integrate.fixture.HintModuloDatabaseShardingAlgorithm in project sharding-jdbc by shardingjdbc.
the class AbstractRoutingDatabaseOnlyWithHintTest method getShardingRule.
@Override
protected ShardingRule getShardingRule(final Map.Entry<DatabaseType, Map<String, DataSource>> dataSourceEntry) {
ShardingRuleConfiguration shardingRuleConfig = new ShardingRuleConfiguration();
shardingRuleConfig.setDefaultDatabaseShardingStrategyConfig(new HintShardingStrategyConfiguration(new HintModuloDatabaseShardingAlgorithm()));
return new ShardingRule(shardingRuleConfig, dataSourceEntry.getValue().keySet());
}
Aggregations