Skip to content

Commit

Permalink
Add debug info
Browse files Browse the repository at this point in the history
  • Loading branch information
terrymanu committed Sep 30, 2023
1 parent d3df661 commit 5616e57
Showing 1 changed file with 8 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@

import lombok.AccessLevel;
import lombok.NoArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.apache.shardingsphere.infra.config.database.DatabaseConfiguration;
import org.apache.shardingsphere.infra.config.rule.RuleConfiguration;
import org.apache.shardingsphere.infra.config.rule.checker.RuleConfigurationChecker;
Expand All @@ -43,6 +44,7 @@
* Database rules builder.
*/
@NoArgsConstructor(access = AccessLevel.PRIVATE)
@Slf4j
public final class DatabaseRulesBuilder {

/**
Expand All @@ -62,6 +64,9 @@ public static Collection<ShardingSphereRule> build(final String databaseName, fi
if (null != configChecker) {
configChecker.check(databaseName, entry.getKey(), databaseConfig.getDataSources(), result);
}
if (entry.getKey().getClass().getName().contains("SingleRule")) {
log.error("========from build1======");
}
result.add(entry.getValue().build(entry.getKey(), databaseName, databaseConfig.getDataSources(), result, instanceContext));
}
return result;
Expand All @@ -88,6 +93,9 @@ public static Collection<ShardingSphereRule> build(final String databaseName, fi
if (null != configChecker) {
configChecker.check(databaseName, entry.getKey(), dataSources, rules);
}
if (entry.getKey().getClass().getName().contains("SingleRule")) {
log.error("========from build2======");
}
result.add(entry.getValue().build(entry.getKey(), databaseName, dataSources, rules, instanceContext));
}
return result;
Expand Down

0 comments on commit 5616e57

Please sign in to comment.