You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by GitBox <gi...@apache.org> on 2021/08/31 13:37:24 UTC

[GitHub] [shardingsphere] terrymanu commented on a change in pull request #12135: Merge governance-spring-boot-starter and jdbc-core-spring-boot-starter

terrymanu commented on a change in pull request #12135:
URL: https://github.com/apache/shardingsphere/pull/12135#discussion_r699330905



##########
File path: shardingsphere-infra/shardingsphere-infra-common/src/main/java/org/apache/shardingsphere/infra/yaml/config/swapper/mode/ModeConfigurationYamlSwapper.java
##########
@@ -40,8 +39,10 @@ public YamlModeConfiguration swapToYamlConfiguration(final ModeConfiguration dat
     
     @Override
     public ModeConfiguration swapToObject(final YamlModeConfiguration yamlConfig) {
-        PersistRepositoryConfiguration repositoryConfig = null == yamlConfig.getRepository()
-                ? null : new PersistRepositoryConfigurationYamlSwapperEngine().swapToObject(yamlConfig.getType(), yamlConfig.getRepository());
-        return new ModeConfiguration(yamlConfig.getType(), repositoryConfig, yamlConfig.isOverwrite());
+        if (null == yamlConfig || null == yamlConfig.getRepository()) {
+            return new ModeConfiguration("Memory", null, false);

Review comment:
       Please avoid use type details such as `Memory` in the up level code.
   Just use RequiredSPI to resolve it.




-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org