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 10:00:42 UTC

[GitHub] [shardingsphere] zjcnb opened a new pull request #12135: Merge governance-spring-boot-starter and jdbc-core-spring-boot-starter

zjcnb opened a new pull request #12135:
URL: https://github.com/apache/shardingsphere/pull/12135


   For #12057 .
   
   Merge shardingsphere-jdbc-governance-spring-boot-starter and shardingsphere-jdbc-core-spring-boot-starter
   


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



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

Posted by GitBox <gi...@apache.org>.
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



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

Posted by GitBox <gi...@apache.org>.
zjcnb commented on a change in pull request #12135:
URL: https://github.com/apache/shardingsphere/pull/12135#discussion_r699346349



##########
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:
       Ok,  i will modify 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



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

Posted by GitBox <gi...@apache.org>.
zjcnb commented on a change in pull request #12135:
URL: https://github.com/apache/shardingsphere/pull/12135#discussion_r699346349



##########
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:
       Ok,  i will modify 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



[GitHub] [shardingsphere] terrymanu merged pull request #12135: Merge governance-spring-boot-starter and jdbc-core-spring-boot-starter

Posted by GitBox <gi...@apache.org>.
terrymanu merged pull request #12135:
URL: https://github.com/apache/shardingsphere/pull/12135


   


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



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

Posted by GitBox <gi...@apache.org>.
zjcnb commented on a change in pull request #12135:
URL: https://github.com/apache/shardingsphere/pull/12135#discussion_r699346349



##########
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:
       Ok,  i will modify 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



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

Posted by GitBox <gi...@apache.org>.
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



[GitHub] [shardingsphere] terrymanu merged pull request #12135: Merge governance-spring-boot-starter and jdbc-core-spring-boot-starter

Posted by GitBox <gi...@apache.org>.
terrymanu merged pull request #12135:
URL: https://github.com/apache/shardingsphere/pull/12135


   


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



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

Posted by GitBox <gi...@apache.org>.
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



[GitHub] [shardingsphere] terrymanu merged pull request #12135: Merge governance-spring-boot-starter and jdbc-core-spring-boot-starter

Posted by GitBox <gi...@apache.org>.
terrymanu merged pull request #12135:
URL: https://github.com/apache/shardingsphere/pull/12135


   


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