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 2022/10/27 07:25:34 UTC

[GitHub] [shardingsphere] pandaapo opened a new pull request, #21789: fix issue: startup application with springboot failed when no rules config.

pandaapo opened a new pull request, #21789:
URL: https://github.com/apache/shardingsphere/pull/21789

   Fixes #21775.
   
   Changes proposed in this pull request:
     - Modify `SHARDING_PREFIX` in `LocalRulesCondition` to make springboot application startup successfully with no rules.
   
   ---
   
   Before committing this PR, I'm sure that I have checked the following options:
   - [x] My code follows the [code of conduct](https://shardingsphere.apache.org/community/en/involved/conduct/code/) of this project.
   - [x] I have self-reviewed the commit code.
   - [ ] I have (or in comment I request) added corresponding labels for the pull request.
   - [ ] I have passed maven check locally : `mvn clean install -B -T2C -DskipTests -Dmaven.javadoc.skip=true -e`.
   - [ ] I have made corresponding changes to the documentation.
   - [ ] I have added corresponding unit tests for my changes.
   


-- 
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] strongduanmu commented on pull request #21789: fix issue: startup application with springboot failed when no rules config.

Posted by GitBox <gi...@apache.org>.
strongduanmu commented on PR #21789:
URL: https://github.com/apache/shardingsphere/pull/21789#issuecomment-1293116584

   Hi @pandaapo, can you comment on the original issue?


-- 
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] strongduanmu merged pull request #21789: fix issue: startup application with springboot failed when no rules config.

Posted by GitBox <gi...@apache.org>.
strongduanmu merged PR #21789:
URL: https://github.com/apache/shardingsphere/pull/21789


-- 
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] pandaapo commented on pull request #21789: fix issue: startup application with springboot failed when no rules config.

Posted by GitBox <gi...@apache.org>.
pandaapo commented on PR #21789:
URL: https://github.com/apache/shardingsphere/pull/21789#issuecomment-1293259400

   > Hi @pandaapo, can you comment on the original issue?
   
   OK.


-- 
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] strongduanmu commented on a diff in pull request #21789: fix issue: startup application with springboot failed when no rules config.

Posted by GitBox <gi...@apache.org>.
strongduanmu commented on code in PR #21789:
URL: https://github.com/apache/shardingsphere/pull/21789#discussion_r1006510507


##########
jdbc/spring/core/spring-boot-starter/src/main/java/org/apache/shardingsphere/spring/boot/rule/LocalRulesCondition.java:
##########
@@ -24,16 +24,16 @@
 import org.springframework.core.type.AnnotatedTypeMetadata;
 
 /**
- * Local rules condition.
+ * Local configuration condition.
  */
 public final class LocalRulesCondition extends SpringBootCondition {

Review Comment:
   Can you rename LocalRulesCondition to ShardingSphereSpringBootCondition? Now this class is not related to rules.



##########
jdbc/spring/core/spring-boot-starter/src/main/java/org/apache/shardingsphere/spring/boot/rule/LocalRulesCondition.java:
##########
@@ -24,16 +24,16 @@
 import org.springframework.core.type.AnnotatedTypeMetadata;
 
 /**
- * Local rules condition.
+ * Local configuration condition.
  */
 public final class LocalRulesCondition extends SpringBootCondition {
     
-    private static final String SHARDING_PREFIX = "spring.shardingsphere.rules";
+    private static final String SHARDING_PREFIX = "spring.shardingsphere";

Review Comment:
   Please add unit test for this logic change.



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