This is an automated email from the ASF dual-hosted git repository.
panjuan pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/shardingsphere.git
The following commit(s) were added to refs/heads/master by this push:
new db559393da8 Refactor YamlBroadcastRuleConfigurationSwapper (#30247)
db559393da8 is described below
commit db559393da81200e79e7314a3ff91fd2dd223395
Author: Liang Zhang <[email protected]>
AuthorDate: Thu Feb 22 22:18:51 2024 +0800
Refactor YamlBroadcastRuleConfigurationSwapper (#30247)
---
.../yaml/swapper/YamlBroadcastRuleConfigurationSwapper.java | 6 +-----
1 file changed, 1 insertion(+), 5 deletions(-)
diff --git
a/features/broadcast/core/src/main/java/org/apache/shardingsphere/broadcast/yaml/swapper/YamlBroadcastRuleConfigurationSwapper.java
b/features/broadcast/core/src/main/java/org/apache/shardingsphere/broadcast/yaml/swapper/YamlBroadcastRuleConfigurationSwapper.java
index c0993be8fab..1e8f6231919 100644
---
a/features/broadcast/core/src/main/java/org/apache/shardingsphere/broadcast/yaml/swapper/YamlBroadcastRuleConfigurationSwapper.java
+++
b/features/broadcast/core/src/main/java/org/apache/shardingsphere/broadcast/yaml/swapper/YamlBroadcastRuleConfigurationSwapper.java
@@ -22,9 +22,6 @@ import
org.apache.shardingsphere.broadcast.constant.BroadcastOrder;
import
org.apache.shardingsphere.broadcast.yaml.config.YamlBroadcastRuleConfiguration;
import
org.apache.shardingsphere.infra.yaml.config.swapper.rule.YamlRuleConfigurationSwapper;
-import java.util.Collection;
-import java.util.LinkedList;
-
/**
* YAML broadcast rule configuration swapper.
*/
@@ -39,8 +36,7 @@ public final class YamlBroadcastRuleConfigurationSwapper
implements YamlRuleConf
@Override
public BroadcastRuleConfiguration swapToObject(final
YamlBroadcastRuleConfiguration yamlConfig) {
- Collection<String> tables = new LinkedList<>(yamlConfig.getTables());
- return new BroadcastRuleConfiguration(tables);
+ return new BroadcastRuleConfiguration(yamlConfig.getTables());
}
@Override