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/11/21 01:31:22 UTC

[GitHub] [shardingsphere] fyname opened a new issue #13719: No qualifying bean of type 'org.apache.shardingsphere.infra.config.mode.ModeConfiguration'

fyname opened a new issue #13719:
URL: https://github.com/apache/shardingsphere/issues/13719


   
   ### Which version of ShardingSphere did you use?
   version: 5.0.0
   
   ### Which project did you use? ShardingSphere-JDBC or ShardingSphere-Proxy?
   use: ShardingSphere-JDBC
   
   ### Expected behavior
   
   ### Actual behavior
   
   ### Reason analyze (If you can)
   
   error:
   java.lang.IllegalStateException: Failed to load ApplicationContext
   
   	at org.springframework.test.context.cache.DefaultCacheAwareContextLoaderDelegate.loadContext(DefaultCacheAwareContextLoaderDelegate.java:132)
   	at org.springframework.test.context.support.DefaultTestContext.getApplicationContext(DefaultTestContext.java:124)
   	at org.springframework.test.context.web.ServletTestExecutionListener.setUpRequestContextIfNecessary(ServletTestExecutionListener.java:190)
   	at org.springframework.test.context.web.ServletTestExecutionListener.prepareTestInstance(ServletTestExecutionListener.java:132)
   	at org.springframework.test.context.TestContextManager.prepareTestInstance(TestContextManager.java:244)
   	at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.createTest(SpringJUnit4ClassRunner.java:227)
   	at org.springframework.test.context.junit4.SpringJUnit4ClassRunner$1.runReflectiveCall(SpringJUnit4ClassRunner.java:289)
   	at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
   	at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.methodBlock(SpringJUnit4ClassRunner.java:291)
   	at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.runChild(SpringJUnit4ClassRunner.java:246)
   	at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.runChild(SpringJUnit4ClassRunner.java:97)
   	at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
   	at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
   	at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
   	at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
   	at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
   	at org.springframework.test.context.junit4.statements.RunBeforeTestClassCallbacks.evaluate(RunBeforeTestClassCallbacks.java:61)
   	at org.springframework.test.context.junit4.statements.RunAfterTestClassCallbacks.evaluate(RunAfterTestClassCallbacks.java:70)
   	at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
   	at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.run(SpringJUnit4ClassRunner.java:190)
   	at org.junit.runner.JUnitCore.run(JUnitCore.java:137)
   	at com.intellij.junit4.JUnit4IdeaTestRunner.startRunnerWithArgs(JUnit4IdeaTestRunner.java:68)
   	at com.intellij.rt.execution.junit.IdeaTestRunner$Repeater.startRunnerWithArgs(IdeaTestRunner.java:47)
   	at com.intellij.rt.execution.junit.JUnitStarter.prepareStreamsAndStart(JUnitStarter.java:242)
   	at com.intellij.rt.execution.junit.JUnitStarter.main(JUnitStarter.java:70)
   Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'orderServiceImpl': Injection of resource dependencies failed; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'orderMapper' defined in file [E:\workspace\multit-tenant\target\classes\com\freesun\shardingsphere\multitenancy\mapper\OrderMapper.class]: Unsatisfied dependency expressed through bean property 'sqlSessionFactory'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'sqlSessionFactory' defined in class path resource [org/mybatis/spring/boot/autoconfigure/MybatisAutoConfiguration.class]: Unsatisfied dependency expressed through method 'sqlSessionFactory' parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'dataSource' defined in class path resource [org/apache/shardingsp
 here/spring/boot/ShardingSphereAutoConfiguration.class]: Unsatisfied dependency expressed through method 'dataSource' parameter 0; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type 'org.apache.shardingsphere.infra.config.mode.ModeConfiguration' available: expected at least 1 bean which qualifies as autowire candidate. Dependency annotations: {}
   	at org.springframework.context.annotation.CommonAnnotationBeanPostProcessor.postProcessProperties(CommonAnnotationBeanPostProcessor.java:321)
   	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1413)
   	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:601)
   	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:524)
   	at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:335)
   	at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:234)
   	at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:333)
   	at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:208)
   	at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:944)
   	at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:918)
   	at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:583)
   	at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:771)
   	at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:763)
   	at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:438)
   	at org.springframework.boot.SpringApplication.run(SpringApplication.java:339)
   	at org.springframework.boot.test.context.SpringBootContextLoader.loadContext(SpringBootContextLoader.java:123)
   	at org.springframework.test.context.cache.DefaultCacheAwareContextLoaderDelegate.loadContextInternal(DefaultCacheAwareContextLoaderDelegate.java:99)
   	at org.springframework.test.context.cache.DefaultCacheAwareContextLoaderDelegate.loadContext(DefaultCacheAwareContextLoaderDelegate.java:124)
   	... 24 more
   Caused by: org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'orderMapper' defined in file [E:\workspace\multit-tenant\target\classes\com\freesun\shardingsphere\multitenancy\mapper\OrderMapper.class]: Unsatisfied dependency expressed through bean property 'sqlSessionFactory'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'sqlSessionFactory' defined in class path resource [org/mybatis/spring/boot/autoconfigure/MybatisAutoConfiguration.class]: Unsatisfied dependency expressed through method 'sqlSessionFactory' parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'dataSource' defined in class path resource [org/apache/shardingsphere/spring/boot/ShardingSphereAutoConfiguration.class]: Unsatisfied dependency expressed through method 'dataSource' parameter 0; nested exception is org.springframework
 .beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type 'org.apache.shardingsphere.infra.config.mode.ModeConfiguration' available: expected at least 1 bean which qualifies as autowire candidate. Dependency annotations: {}
   	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.autowireByType(AbstractAutowireCapableBeanFactory.java:1516)
   	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.populateBean(AbstractAutowireCapableBeanFactory.java:1399)
   	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:601)
   	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:524)
   	at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:335)
   	at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:234)
   	at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:333)
   	at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:213)
   	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.resolveBeanByName(AbstractAutowireCapableBeanFactory.java:461)
   	at org.springframework.context.annotation.CommonAnnotationBeanPostProcessor.autowireResource(CommonAnnotationBeanPostProcessor.java:527)
   	at org.springframework.context.annotation.CommonAnnotationBeanPostProcessor.getResource(CommonAnnotationBeanPostProcessor.java:497)
   	at org.springframework.context.annotation.CommonAnnotationBeanPostProcessor$ResourceElement.getResourceToInject(CommonAnnotationBeanPostProcessor.java:650)
   	at org.springframework.beans.factory.annotation.InjectionMetadata$InjectedElement.inject(InjectionMetadata.java:228)
   	at org.springframework.beans.factory.annotation.InjectionMetadata.inject(InjectionMetadata.java:119)
   	at org.springframework.context.annotation.CommonAnnotationBeanPostProcessor.postProcessProperties(CommonAnnotationBeanPostProcessor.java:318)
   	... 41 more
   Caused by: org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'sqlSessionFactory' defined in class path resource [org/mybatis/spring/boot/autoconfigure/MybatisAutoConfiguration.class]: Unsatisfied dependency expressed through method 'sqlSessionFactory' parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'dataSource' defined in class path resource [org/apache/shardingsphere/spring/boot/ShardingSphereAutoConfiguration.class]: Unsatisfied dependency expressed through method 'dataSource' parameter 0; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type 'org.apache.shardingsphere.infra.config.mode.ModeConfiguration' available: expected at least 1 bean which qualifies as autowire candidate. Dependency annotations: {}
   	at org.springframework.beans.factory.support.ConstructorResolver.createArgumentArray(ConstructorResolver.java:800)
   	at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:541)
   	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(AbstractAutowireCapableBeanFactory.java:1334)
   	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1177)
   	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:564)
   	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:524)
   	at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:335)
   	at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:234)
   	at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:333)
   	at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:208)
   	at org.springframework.beans.factory.config.DependencyDescriptor.resolveCandidate(DependencyDescriptor.java:276)
   	at org.springframework.beans.factory.support.DefaultListableBeanFactory.doResolveDependency(DefaultListableBeanFactory.java:1380)
   	at org.springframework.beans.factory.support.DefaultListableBeanFactory.resolveDependency(DefaultListableBeanFactory.java:1300)
   	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.autowireByType(AbstractAutowireCapableBeanFactory.java:1501)
   	... 55 more
   Caused by: org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'dataSource' defined in class path resource [org/apache/shardingsphere/spring/boot/ShardingSphereAutoConfiguration.class]: Unsatisfied dependency expressed through method 'dataSource' parameter 0; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type 'org.apache.shardingsphere.infra.config.mode.ModeConfiguration' available: expected at least 1 bean which qualifies as autowire candidate. Dependency annotations: {}
   	at org.springframework.beans.factory.support.ConstructorResolver.createArgumentArray(ConstructorResolver.java:800)
   	at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:541)
   	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(AbstractAutowireCapableBeanFactory.java:1334)
   	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1177)
   	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:564)
   	at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:524)
   	at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:335)
   	at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:234)
   	at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:333)
   	at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:208)
   	at org.springframework.beans.factory.config.DependencyDescriptor.resolveCandidate(DependencyDescriptor.java:276)
   	at org.springframework.beans.factory.support.DefaultListableBeanFactory.doResolveDependency(DefaultListableBeanFactory.java:1380)
   	at org.springframework.beans.factory.support.DefaultListableBeanFactory.resolveDependency(DefaultListableBeanFactory.java:1300)
   	at org.springframework.beans.factory.support.ConstructorResolver.resolveAutowiredArgument(ConstructorResolver.java:887)
   	at org.springframework.beans.factory.support.ConstructorResolver.createArgumentArray(ConstructorResolver.java:791)
   	... 68 more
   Caused by: org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type 'org.apache.shardingsphere.infra.config.mode.ModeConfiguration' available: expected at least 1 bean which qualifies as autowire candidate. Dependency annotations: {}
   	at org.springframework.beans.factory.support.DefaultListableBeanFactory.raiseNoMatchingBeanFound(DefaultListableBeanFactory.java:1790)
   	at org.springframework.beans.factory.support.DefaultListableBeanFactory.doResolveDependency(DefaultListableBeanFactory.java:1385)
   	at org.springframework.beans.factory.support.DefaultListableBeanFactory.resolveDependency(DefaultListableBeanFactory.java:1300)
   	at org.springframework.beans.factory.support.ConstructorResolver.resolveAutowiredArgument(ConstructorResolver.java:887)
   	at org.springframework.beans.factory.support.ConstructorResolver.createArgumentArray(ConstructorResolver.java:791)
   	... 82 more
   
   
   
   ### Steps to reproduce the behavior, such as: SQL to execute, sharding rule configuration, when exception occur etc.
   
   ### Example codes for reproduce this issue (such as a github link).
   


-- 
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] fyname commented on issue #13719: No qualifying bean of type 'org.apache.shardingsphere.infra.config.mode.ModeConfiguration'

Posted by GitBox <gi...@apache.org>.
fyname commented on issue #13719:
URL: https://github.com/apache/shardingsphere/issues/13719#issuecomment-974991723


   hello 
   update  bootstrap.yml to application.yml and remove @activeprofiles("sharding") in OrderSpringBootTests
   
   New mistakes appear:
   Caused by: org.apache.shardingsphere.spi.exception.ServiceProviderNotFoundException: No implementation class load from SPI `org.apache.shardingsphere.sharding.spi.ShardingAlgorithm` with type `null`.
   	at org.apache.shardingsphere.spi.typed.TypedSPIRegistry.getRegisteredService(TypedSPIRegistry.java:76)
   	at org.apache.shardingsphere.spring.boot.registry.AbstractAlgorithmProvidedBeanRegistry.lambda$registerBean$2(AbstractAlgorithmProvidedBeanRegistry.java:78)
   	at java.util.LinkedHashMap.forEach(LinkedHashMap.java:684)
   	at org.apache.shardingsphere.spring.boot.registry.AbstractAlgorithmProvidedBeanRegistry.registerBean(AbstractAlgorithmProvidedBeanRegistry.java:77)
   	at org.apache.shardingsphere.sharding.spring.boot.algorithm.ShardingAlgorithmProvidedBeanRegistry.postProcessBeanDefinitionRegistry(ShardingAlgorithmProvidedBeanRegistry.java:38)
   	at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanDefinitionRegistryPostProcessors(PostProcessorRegistrationDelegate.java:311)
   	at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanFactoryPostProcessors(PostProcessorRegistrationDelegate.java:142)
   	at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:746)
   	at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:564)
   	at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:771)
   	at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:763)
   	at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:438)
   	at org.springframework.boot.SpringApplication.run(SpringApplication.java:339)
   	at org.springframework.boot.test.context.SpringBootContextLoader.loadContext(SpringBootContextLoader.java:123)
   	at org.springframework.test.context.cache.DefaultCacheAwareContextLoaderDelegate.loadContextInternal(DefaultCacheAwareContextLoaderDelegate.java:99)
   	at org.springframework.test.context.cache.DefaultCacheAwareContextLoaderDelegate.loadContext(DefaultCacheAwareContextLoaderDelegate.java:124)


-- 
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 issue #13719: No qualifying bean of type 'org.apache.shardingsphere.infra.config.mode.ModeConfiguration'

Posted by GitBox <gi...@apache.org>.
zjcnb commented on issue #13719:
URL: https://github.com/apache/shardingsphere/issues/13719#issuecomment-974763862


   @fyname You can change bootstrap.yml to application.yml and remove @ActiveProfiles("sharding") in OrderSpringBootTests.calss.


-- 
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] fyname commented on issue #13719: No qualifying bean of type 'org.apache.shardingsphere.infra.config.mode.ModeConfiguration'

Posted by GitBox <gi...@apache.org>.
fyname commented on issue #13719:
URL: https://github.com/apache/shardingsphere/issues/13719#issuecomment-976295582


   config yml is 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] fyname removed a comment on issue #13719: No qualifying bean of type 'org.apache.shardingsphere.infra.config.mode.ModeConfiguration'

Posted by GitBox <gi...@apache.org>.
fyname removed a comment on issue #13719:
URL: https://github.com/apache/shardingsphere/issues/13719#issuecomment-974991723


   hello 
   update  bootstrap.yml to application.yml and remove @activeprofiles("sharding") in OrderSpringBootTests
   
   New mistakes appear:
   **Caused by: org.apache.shardingsphere.spi.exception.ServiceProviderNotFoundException: No implementation class load from SPI `org.apache.shardingsphere.sharding.spi.ShardingAlgorithm` with type `null`.**
   	at org.apache.shardingsphere.spi.typed.TypedSPIRegistry.getRegisteredService(TypedSPIRegistry.java:76)
   	at org.apache.shardingsphere.spring.boot.registry.AbstractAlgorithmProvidedBeanRegistry.lambda$registerBean$2(AbstractAlgorithmProvidedBeanRegistry.java:78)
   	at java.util.LinkedHashMap.forEach(LinkedHashMap.java:684)
   	at org.apache.shardingsphere.spring.boot.registry.AbstractAlgorithmProvidedBeanRegistry.registerBean(AbstractAlgorithmProvidedBeanRegistry.java:77)
   	at org.apache.shardingsphere.sharding.spring.boot.algorithm.ShardingAlgorithmProvidedBeanRegistry.postProcessBeanDefinitionRegistry(ShardingAlgorithmProvidedBeanRegistry.java:38)
   	at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanDefinitionRegistryPostProcessors(PostProcessorRegistrationDelegate.java:311)
   	at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanFactoryPostProcessors(PostProcessorRegistrationDelegate.java:142)
   	at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:746)
   	at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:564)
   	at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:771)
   	at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:763)
   	at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:438)
   	at org.springframework.boot.SpringApplication.run(SpringApplication.java:339)
   	at org.springframework.boot.test.context.SpringBootContextLoader.loadContext(SpringBootContextLoader.java:123)
   	at org.springframework.test.context.cache.DefaultCacheAwareContextLoaderDelegate.loadContextInternal(DefaultCacheAwareContextLoaderDelegate.java:99)
   	at org.springframework.test.context.cache.DefaultCacheAwareContextLoaderDelegate.loadContext(DefaultCacheAwareContextLoaderDelegate.java:124)
   
   github:  https://github.com/fyname/multit-tenant.git


-- 
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] fyname commented on issue #13719: No qualifying bean of type 'org.apache.shardingsphere.infra.config.mode.ModeConfiguration'

Posted by GitBox <gi...@apache.org>.
fyname commented on issue #13719:
URL: https://github.com/apache/shardingsphere/issues/13719#issuecomment-976295757


   config yml is 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] zjcnb commented on issue #13719: No qualifying bean of type 'org.apache.shardingsphere.infra.config.mode.ModeConfiguration'

Posted by GitBox <gi...@apache.org>.
zjcnb commented on issue #13719:
URL: https://github.com/apache/shardingsphere/issues/13719#issuecomment-974763862


   @fyname You can change bootstrap.yml to application.yml and remove @ActiveProfiles("sharding") in OrderSpringBootTests.calss.


-- 
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] fyname edited a comment on issue #13719: No qualifying bean of type 'org.apache.shardingsphere.infra.config.mode.ModeConfiguration'

Posted by GitBox <gi...@apache.org>.
fyname edited a comment on issue #13719:
URL: https://github.com/apache/shardingsphere/issues/13719#issuecomment-974991723


   hello 
   update  bootstrap.yml to application.yml and remove @activeprofiles("sharding") in OrderSpringBootTests
   
   New mistakes appear:
   **Caused by: org.apache.shardingsphere.spi.exception.ServiceProviderNotFoundException: No implementation class load from SPI `org.apache.shardingsphere.sharding.spi.ShardingAlgorithm` with type `null`.**
   	at org.apache.shardingsphere.spi.typed.TypedSPIRegistry.getRegisteredService(TypedSPIRegistry.java:76)
   	at org.apache.shardingsphere.spring.boot.registry.AbstractAlgorithmProvidedBeanRegistry.lambda$registerBean$2(AbstractAlgorithmProvidedBeanRegistry.java:78)
   	at java.util.LinkedHashMap.forEach(LinkedHashMap.java:684)
   	at org.apache.shardingsphere.spring.boot.registry.AbstractAlgorithmProvidedBeanRegistry.registerBean(AbstractAlgorithmProvidedBeanRegistry.java:77)
   	at org.apache.shardingsphere.sharding.spring.boot.algorithm.ShardingAlgorithmProvidedBeanRegistry.postProcessBeanDefinitionRegistry(ShardingAlgorithmProvidedBeanRegistry.java:38)
   	at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanDefinitionRegistryPostProcessors(PostProcessorRegistrationDelegate.java:311)
   	at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanFactoryPostProcessors(PostProcessorRegistrationDelegate.java:142)
   	at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:746)
   	at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:564)
   	at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:771)
   	at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:763)
   	at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:438)
   	at org.springframework.boot.SpringApplication.run(SpringApplication.java:339)
   	at org.springframework.boot.test.context.SpringBootContextLoader.loadContext(SpringBootContextLoader.java:123)
   	at org.springframework.test.context.cache.DefaultCacheAwareContextLoaderDelegate.loadContextInternal(DefaultCacheAwareContextLoaderDelegate.java:99)
   	at org.springframework.test.context.cache.DefaultCacheAwareContextLoaderDelegate.loadContext(DefaultCacheAwareContextLoaderDelegate.java:124)
   
   github:  https://github.com/fyname/multit-tenant.git


-- 
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] fyname edited a comment on issue #13719: No qualifying bean of type 'org.apache.shardingsphere.infra.config.mode.ModeConfiguration'

Posted by GitBox <gi...@apache.org>.
fyname edited a comment on issue #13719:
URL: https://github.com/apache/shardingsphere/issues/13719#issuecomment-974991723


   hello 
   update  bootstrap.yml to application.yml and remove @activeprofiles("sharding") in OrderSpringBootTests
   
   New mistakes appear:
   Caused by: org.apache.shardingsphere.spi.exception.ServiceProviderNotFoundException: No implementation class load from SPI `org.apache.shardingsphere.sharding.spi.ShardingAlgorithm` with type `null`.
   	at org.apache.shardingsphere.spi.typed.TypedSPIRegistry.getRegisteredService(TypedSPIRegistry.java:76)
   	at org.apache.shardingsphere.spring.boot.registry.AbstractAlgorithmProvidedBeanRegistry.lambda$registerBean$2(AbstractAlgorithmProvidedBeanRegistry.java:78)
   	at java.util.LinkedHashMap.forEach(LinkedHashMap.java:684)
   	at org.apache.shardingsphere.spring.boot.registry.AbstractAlgorithmProvidedBeanRegistry.registerBean(AbstractAlgorithmProvidedBeanRegistry.java:77)
   	at org.apache.shardingsphere.sharding.spring.boot.algorithm.ShardingAlgorithmProvidedBeanRegistry.postProcessBeanDefinitionRegistry(ShardingAlgorithmProvidedBeanRegistry.java:38)
   	at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanDefinitionRegistryPostProcessors(PostProcessorRegistrationDelegate.java:311)
   	at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanFactoryPostProcessors(PostProcessorRegistrationDelegate.java:142)
   	at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:746)
   	at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:564)
   	at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:771)
   	at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:763)
   	at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:438)
   	at org.springframework.boot.SpringApplication.run(SpringApplication.java:339)
   	at org.springframework.boot.test.context.SpringBootContextLoader.loadContext(SpringBootContextLoader.java:123)
   	at org.springframework.test.context.cache.DefaultCacheAwareContextLoaderDelegate.loadContextInternal(DefaultCacheAwareContextLoaderDelegate.java:99)
   	at org.springframework.test.context.cache.DefaultCacheAwareContextLoaderDelegate.loadContext(DefaultCacheAwareContextLoaderDelegate.java:124)
   
   github:  https://github.com/fyname/multit-tenant.git


-- 
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] fyname commented on issue #13719: No qualifying bean of type 'org.apache.shardingsphere.infra.config.mode.ModeConfiguration'

Posted by GitBox <gi...@apache.org>.
fyname commented on issue #13719:
URL: https://github.com/apache/shardingsphere/issues/13719#issuecomment-976069697


   > ```
   > mybatis:
   >   mapper-locations: classpath:mapper/*.xml
   >   type-aliases-package: com.freesun.shardingsphere.multitenancy.model
   > 
   > spring:
   >   shardingsphere:
   >     mode:
   >       type: Memory
   >     schema:
   >       name: multit-tenant
   >     datasource:
   >       names: aliyun,tmall,taobao
   >       aliyun:
   >         type: com.zaxxer.hikari.HikariDataSource
   >         driver-class-name: com.mysql.jdbc.Driver
   >         jdbc-url: jdbc:mysql://127.0.0.1:3306/aliyun?serverTimezone=UTC&useSSL=false&useUnicode=true&characterEncoding=UTF-8
   >         username: root
   >         password: 123456
   >       taobao:
   >         type: com.zaxxer.hikari.HikariDataSource
   >         driver-class-name: com.mysql.jdbc.Driver
   >         jdbc-url: jdbc:mysql://127.0.0.1:3306/taobao?serverTimezone=UTC&useSSL=false&useUnicode=true&characterEncoding=UTF-8
   >         username: root
   >         password: 123456
   >       tmall:
   >         type: com.zaxxer.hikari.HikariDataSource
   >         driver-class-name: com.mysql.jdbc.Driver
   >         jdbc-url: jdbc:mysql://127.0.0.1:3306/tmall?serverTimezone=UTC&useSSL=false&useUnicode=true&characterEncoding=UTF-8
   >         username: root
   >         password: 123456
   >     rules:
   >       sharding:
   >         tables:
   >           t_order:
   >             actualDataNodes: tmall.tb_order,taobao.tb_order,aliyun.tb_order
   >             keyGenerateStrategy:
   >               column: order_id
   >               keyGeneratorName: snowflake
   >         defaultDatabaseStrategy:
   >           standard:
   >             shardingColumn: merchant
   >             shardingAlgorithmName: db-classbased
   >         defaultTableStrategy:
   >           none:
   > 
   >         shardingAlgorithms:
   >           db-classbased:
   >             type: CLASS_BASED
   >             props:
   >               strategy: standard
   >               algorithmClassName: com.freesun.shardingsphere.multitenancy.spi.DbShardingAlgorithm
   > 
   >         keyGenerators:
   >           snowflake:
   >             type: SNOWFLAKE
   >             props:
   >               worker-id: 123
   > ```
   > 
   > Replace your configuration.
   
   HI 
   
   Custom SPI not called found
   The shardingwehre interface is not introduced, the call is normal, and the data is saved to MySQL
   The SQL exception occurred in the configuration after reference is as follows:
   
   org.springframework.dao.TransientDataAccessResourceException: 
   ### Error updating database.  Cause: java.sql.SQLException: Parameter index out of range (1 > number of parameters, which is 0).
   ### The error may exist in file [D:\workspace\multit-tenant\target\classes\com\freesun\shardingsphere\multitenancy\dao\OrderMapper.xml]
   ### The error may involve com.freesun.shardingsphere.multitenancy.dao.OrderDAO.save-Inline
   ### The error occurred while setting parameters
   ### SQL: insert into tb_order         (             `user_id`,             `order_no`,             `order_time`,             `merchant`         )         values         (             ?,             ?,             ?,             ?         )
   ### Cause: java.sql.SQLException: Parameter index out of range (1 > number of parameters, which is 0).
   ; **Parameter index out of range (1 > number of parameters, which is 0).; nested exception is java.sql.SQLException: Parameter index out of range (1 > number of parameters, which is 0).**
   
   	at org.springframework.jdbc.support.SQLStateSQLExceptionTranslator.doTranslate(SQLStateSQLExceptionTranslator.java:110)
   	at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:70)
   	at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:79)
   	at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:79)
   	at org.mybatis.spring.MyBatisExceptionTranslator.translateExceptionIfPossible(MyBatisExceptionTranslator.java:88)
   	at org.mybatis.spring.SqlSessionTemplate$SqlSessionInterceptor.invoke(SqlSessionTemplate.java:440)
   	at com.sun.proxy.$Proxy203.insert(Unknown Source)
   	at org.mybatis.spring.SqlSessionTemplate.insert(SqlSessionTemplate.java:271)
   	at com.freesun.shardingsphere.multitenancy.dao.OrderDAOImpl.save(OrderDAOImpl.java:20)
   	at com.freesun.shardingsphere.multitenancy.dao.OrderDAOImpl$$FastClassBySpringCGLIB$$4237c205.invoke(<generated>)
   	at org.springframework.cglib.proxy.MethodProxy.invoke(MethodProxy.java:218)
   	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.invokeJoinpoint(CglibAopProxy.java:779)
   	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163)
   	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:750)
   	at org.springframework.dao.support.PersistenceExceptionTranslationInterceptor.invoke(PersistenceExceptionTranslationInterceptor.java:137)
   	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
   	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:750)
   	at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:692)
   	at com.freesun.shardingsphere.multitenancy.dao.OrderDAOImpl$$EnhancerBySpringCGLIB$$1c726bff.save(<generated>)
   	at com.freesun.shardingsphere.multitenancy.service.impl.OrderServiceImpl.save(OrderServiceImpl.java:17)
   	at com.freesun.shardingsphere.multitenancy.OrderSpringBootTests.save(OrderSpringBootTests.java:45)
   	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
   	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
   	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
   	at java.lang.reflect.Method.invoke(Method.java:498)
   	at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50)
   	at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
   	at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47)
   	at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
   	at org.springframework.test.context.junit4.statements.RunBeforeTestExecutionCallbacks.evaluate(RunBeforeTestExecutionCallbacks.java:74)
   	at org.springframework.test.context.junit4.statements.RunAfterTestExecutionCallbacks.evaluate(RunAfterTestExecutionCallbacks.java:84)
   	at org.springframework.test.context.junit4.statements.RunBeforeTestMethodCallbacks.evaluate(RunBeforeTestMethodCallbacks.java:75)
   	at org.springframework.test.context.junit4.statements.RunAfterTestMethodCallbacks.evaluate(RunAfterTestMethodCallbacks.java:86)
   	at org.springframework.test.context.junit4.statements.SpringRepeat.evaluate(SpringRepeat.java:84)
   	at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:325)
   	at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.runChild(SpringJUnit4ClassRunner.java:251)
   	at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.runChild(SpringJUnit4ClassRunner.java:97)
   	at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
   	at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
   	at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
   	at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
   	at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
   	at org.springframework.test.context.junit4.statements.RunBeforeTestClassCallbacks.evaluate(RunBeforeTestClassCallbacks.java:61)
   	at org.springframework.test.context.junit4.statements.RunAfterTestClassCallbacks.evaluate(RunAfterTestClassCallbacks.java:70)
   	at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
   	at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.run(SpringJUnit4ClassRunner.java:190)
   	at org.junit.runner.JUnitCore.run(JUnitCore.java:137)
   	at com.intellij.junit4.JUnit4IdeaTestRunner.startRunnerWithArgs(JUnit4IdeaTestRunner.java:69)
   	at com.intellij.rt.junit.IdeaTestRunner$Repeater.startRunnerWithArgs(IdeaTestRunner.java:33)
   	at com.intellij.rt.junit.JUnitStarter.prepareStreamsAndStart(JUnitStarter.java:221)
   	at com.intellij.rt.junit.JUnitStarter.main(JUnitStarter.java:54)
   Caused by: java.sql.SQLException: Parameter index out of range (1 > number of parameters, which is 0).
   	at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:965)
   	at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:898)
   	at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:887)
   	at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:861)
   	at com.mysql.jdbc.PreparedStatement.checkBounds(PreparedStatement.java:3385)
   	at com.mysql.jdbc.PreparedStatement.setInternal(PreparedStatement.java:3370)
   	at com.mysql.jdbc.PreparedStatement.setInternal(PreparedStatement.java:3409)
   	at com.mysql.jdbc.PreparedStatement.setInt(PreparedStatement.java:3360)
   	at com.mysql.jdbc.PreparedStatement.setObject(PreparedStatement.java:3595)
   	at com.mysql.jdbc.JDBC42PreparedStatement.setObject(JDBC42PreparedStatement.java:68)
   	at com.zaxxer.hikari.pool.HikariProxyPreparedStatement.setObject(HikariProxyPreparedStatement.java)
   	at org.apache.shardingsphere.driver.jdbc.adapter.AbstractPreparedStatementAdapter.lambda$addParameters$0(AbstractPreparedStatementAdapter.java:289)
   	at org.apache.shardingsphere.driver.jdbc.adapter.AbstractPreparedStatementAdapter.replaySetParameter(AbstractPreparedStatementAdapter.java:281)
   	at org.apache.shardingsphere.driver.jdbc.core.statement.ShardingSpherePreparedStatement.replaySetParameter(ShardingSpherePreparedStatement.java:415)
   	at org.apache.shardingsphere.driver.jdbc.core.statement.ShardingSpherePreparedStatement.replay(ShardingSpherePreparedStatement.java:407)
   	at org.apache.shardingsphere.driver.jdbc.core.statement.ShardingSpherePreparedStatement.cacheStatements(ShardingSpherePreparedStatement.java:403)
   	at org.apache.shardingsphere.driver.jdbc.core.statement.ShardingSpherePreparedStatement.execute(ShardingSpherePreparedStatement.java:297)
   	at org.apache.ibatis.executor.statement.PreparedStatementHandler.update(PreparedStatementHandler.java:47)
   	at org.apache.ibatis.executor.statement.RoutingStatementHandler.update(RoutingStatementHandler.java:74)
   	at org.apache.ibatis.executor.SimpleExecutor.doUpdate(SimpleExecutor.java:50)
   	at org.apache.ibatis.executor.BaseExecutor.update(BaseExecutor.java:117)
   	at org.apache.ibatis.executor.CachingExecutor.update(CachingExecutor.java:76)
   	at org.apache.ibatis.session.defaults.DefaultSqlSession.update(DefaultSqlSession.java:197)
   	at org.apache.ibatis.session.defaults.DefaultSqlSession.insert(DefaultSqlSession.java:184)
   	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
   	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
   	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
   	at java.lang.reflect.Method.invoke(Method.java:498)
   	at org.mybatis.spring.SqlSessionTemplate$SqlSessionInterceptor.invoke(SqlSessionTemplate.java:426)
   	... 45 more
   


-- 
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] fyname removed a comment on issue #13719: No qualifying bean of type 'org.apache.shardingsphere.infra.config.mode.ModeConfiguration'

Posted by GitBox <gi...@apache.org>.
fyname removed a comment on issue #13719:
URL: https://github.com/apache/shardingsphere/issues/13719#issuecomment-976295582


   config yml is 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] zjcnb commented on issue #13719: No qualifying bean of type 'org.apache.shardingsphere.infra.config.mode.ModeConfiguration'

Posted by GitBox <gi...@apache.org>.
zjcnb commented on issue #13719:
URL: https://github.com/apache/shardingsphere/issues/13719#issuecomment-975014288


   
   ```
   mybatis:
     mapper-locations: classpath:mapper/*.xml
     type-aliases-package: com.freesun.shardingsphere.multitenancy.model
   
   spring:
     shardingsphere:
       mode:
         type: Memory
       schema:
         name: multit-tenant
       datasource:
         names: aliyun,tmall,taobao
         aliyun:
           type: com.zaxxer.hikari.HikariDataSource
           driver-class-name: com.mysql.jdbc.Driver
           jdbc-url: jdbc:mysql://127.0.0.1:3306/aliyun?serverTimezone=UTC&useSSL=false&useUnicode=true&characterEncoding=UTF-8
           username: root
           password: 123456
         taobao:
           type: com.zaxxer.hikari.HikariDataSource
           driver-class-name: com.mysql.jdbc.Driver
           jdbc-url: jdbc:mysql://127.0.0.1:3306/taobao?serverTimezone=UTC&useSSL=false&useUnicode=true&characterEncoding=UTF-8
           username: root
           password: 123456
         tmall:
           type: com.zaxxer.hikari.HikariDataSource
           driver-class-name: com.mysql.jdbc.Driver
           jdbc-url: jdbc:mysql://127.0.0.1:3306/tmall?serverTimezone=UTC&useSSL=false&useUnicode=true&characterEncoding=UTF-8
           username: root
           password: 123456
       rules:
         sharding:
           tables:
             t_order:
               actualDataNodes: tmall.tb_order,taobao.tb_order,aliyun.tb_order
               keyGenerateStrategy:
                 column: order_id
                 keyGeneratorName: snowflake
           defaultDatabaseStrategy:
             standard:
               shardingColumn: merchant
               shardingAlgorithmName: db-classbased
           defaultTableStrategy:
             none:
   
           shardingAlgorithms:
             db-classbased:
               type: CLASS_BASED
               props:
                 strategy: standard
                 algorithmClassName: com.freesun.shardingsphere.multitenancy.spi.DbShardingAlgorithm
   
           keyGenerators:
             snowflake:
               type: SNOWFLAKE
               props:
                 worker-id: 123
   ```
   
   Replace your configuration.


-- 
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] fyname edited a comment on issue #13719: No qualifying bean of type 'org.apache.shardingsphere.infra.config.mode.ModeConfiguration'

Posted by GitBox <gi...@apache.org>.
fyname edited a comment on issue #13719:
URL: https://github.com/apache/shardingsphere/issues/13719#issuecomment-976069697


   > ```
   > mybatis:
   >   mapper-locations: classpath:mapper/*.xml
   >   type-aliases-package: com.freesun.shardingsphere.multitenancy.model
   > 
   > spring:
   >   shardingsphere:
   >     mode:
   >       type: Memory
   >     schema:
   >       name: multit-tenant
   >     datasource:
   >       names: aliyun,tmall,taobao
   >       aliyun:
   >         type: com.zaxxer.hikari.HikariDataSource
   >         driver-class-name: com.mysql.jdbc.Driver
   >         jdbc-url: jdbc:mysql://127.0.0.1:3306/aliyun?serverTimezone=UTC&useSSL=false&useUnicode=true&characterEncoding=UTF-8
   >         username: root
   >         password: 123456
   >       taobao:
   >         type: com.zaxxer.hikari.HikariDataSource
   >         driver-class-name: com.mysql.jdbc.Driver
   >         jdbc-url: jdbc:mysql://127.0.0.1:3306/taobao?serverTimezone=UTC&useSSL=false&useUnicode=true&characterEncoding=UTF-8
   >         username: root
   >         password: 123456
   >       tmall:
   >         type: com.zaxxer.hikari.HikariDataSource
   >         driver-class-name: com.mysql.jdbc.Driver
   >         jdbc-url: jdbc:mysql://127.0.0.1:3306/tmall?serverTimezone=UTC&useSSL=false&useUnicode=true&characterEncoding=UTF-8
   >         username: root
   >         password: 123456
   >     rules:
   >       sharding:
   >         tables:
   >           t_order:
   >             actualDataNodes: tmall.tb_order,taobao.tb_order,aliyun.tb_order
   >             keyGenerateStrategy:
   >               column: order_id
   >               keyGeneratorName: snowflake
   >         defaultDatabaseStrategy:
   >           standard:
   >             shardingColumn: merchant
   >             shardingAlgorithmName: db-classbased
   >         defaultTableStrategy:
   >           none:
   > 
   >         shardingAlgorithms:
   >           db-classbased:
   >             type: CLASS_BASED
   >             props:
   >               strategy: standard
   >               algorithmClassName: com.freesun.shardingsphere.multitenancy.spi.DbShardingAlgorithm
   > 
   >         keyGenerators:
   >           snowflake:
   >             type: SNOWFLAKE
   >             props:
   >               worker-id: 123
   > ```
   > 
   > Replace your configuration.
   
   HI 
   
   Custom SPI not called found
   The shardingwehre interface is not introduced, the call is normal, and the data is saved to MySQL
   The SQL exception occurred in the configuration after reference is as follows:
   
   org.springframework.dao.TransientDataAccessResourceException: 
   ### Error updating database.  Cause: java.sql.SQLException: Parameter index out of range (1 > number of parameters, which is 0).
   ### The error may exist in file [D:\workspace\multit-tenant\target\classes\com\freesun\shardingsphere\multitenancy\dao\OrderMapper.xml]
   ### The error may involve com.freesun.shardingsphere.multitenancy.dao.OrderDAO.save-Inline
   ### The error occurred while setting parameters
   ### SQL: insert into tb_order         (             `user_id`,             `order_no`,             `order_time`,             `merchant`         )         values         (             ?,             ?,             ?,             ?         )
   ### Cause: java.sql.SQLException: Parameter index out of range (1 > number of parameters, which is 0).
   ; **Parameter index out of range (1 > number of parameters, which is 0).; nested exception is java.sql.SQLException: Parameter index out of range (1 > number of parameters, which is 0).**
   
   	at org.springframework.jdbc.support.SQLStateSQLExceptionTranslator.doTranslate(SQLStateSQLExceptionTranslator.java:110)
   	at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:70)
   	at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:79)
   	at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:79)
   	at org.mybatis.spring.MyBatisExceptionTranslator.translateExceptionIfPossible(MyBatisExceptionTranslator.java:88)
   	at org.mybatis.spring.SqlSessionTemplate$SqlSessionInterceptor.invoke(SqlSessionTemplate.java:440)
   	at com.sun.proxy.$Proxy203.insert(Unknown Source)
   	at org.mybatis.spring.SqlSessionTemplate.insert(SqlSessionTemplate.java:271)
   	at com.freesun.shardingsphere.multitenancy.dao.OrderDAOImpl.save(OrderDAOImpl.java:20)
   	at com.freesun.shardingsphere.multitenancy.dao.OrderDAOImpl$$FastClassBySpringCGLIB$$4237c205.invoke(<generated>)
   	at org.springframework.cglib.proxy.MethodProxy.invoke(MethodProxy.java:218)
   	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.invokeJoinpoint(CglibAopProxy.java:779)
   	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163)
   	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:750)
   	at org.springframework.dao.support.PersistenceExceptionTranslationInterceptor.invoke(PersistenceExceptionTranslationInterceptor.java:137)
   	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
   	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:750)
   	at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:692)
   	at com.freesun.shardingsphere.multitenancy.dao.OrderDAOImpl$$EnhancerBySpringCGLIB$$1c726bff.save(<generated>)
   	at com.freesun.shardingsphere.multitenancy.service.impl.OrderServiceImpl.save(OrderServiceImpl.java:17)
   	at com.freesun.shardingsphere.multitenancy.OrderSpringBootTests.save(OrderSpringBootTests.java:45)
   	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
   	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
   	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
   	at java.lang.reflect.Method.invoke(Method.java:498)
   	at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50)
   	at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
   	at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47)
   	at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
   	at org.springframework.test.context.junit4.statements.RunBeforeTestExecutionCallbacks.evaluate(RunBeforeTestExecutionCallbacks.java:74)
   	at org.springframework.test.context.junit4.statements.RunAfterTestExecutionCallbacks.evaluate(RunAfterTestExecutionCallbacks.java:84)
   	at org.springframework.test.context.junit4.statements.RunBeforeTestMethodCallbacks.evaluate(RunBeforeTestMethodCallbacks.java:75)
   	at org.springframework.test.context.junit4.statements.RunAfterTestMethodCallbacks.evaluate(RunAfterTestMethodCallbacks.java:86)
   	at org.springframework.test.context.junit4.statements.SpringRepeat.evaluate(SpringRepeat.java:84)
   	at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:325)
   	at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.runChild(SpringJUnit4ClassRunner.java:251)
   	at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.runChild(SpringJUnit4ClassRunner.java:97)
   	at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
   	at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
   	at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
   	at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
   	at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
   	at org.springframework.test.context.junit4.statements.RunBeforeTestClassCallbacks.evaluate(RunBeforeTestClassCallbacks.java:61)
   	at org.springframework.test.context.junit4.statements.RunAfterTestClassCallbacks.evaluate(RunAfterTestClassCallbacks.java:70)
   	at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
   	at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.run(SpringJUnit4ClassRunner.java:190)
   	at org.junit.runner.JUnitCore.run(JUnitCore.java:137)
   	at com.intellij.junit4.JUnit4IdeaTestRunner.startRunnerWithArgs(JUnit4IdeaTestRunner.java:69)
   	at com.intellij.rt.junit.IdeaTestRunner$Repeater.startRunnerWithArgs(IdeaTestRunner.java:33)
   	at com.intellij.rt.junit.JUnitStarter.prepareStreamsAndStart(JUnitStarter.java:221)
   	at com.intellij.rt.junit.JUnitStarter.main(JUnitStarter.java:54)
   Caused by: java.sql.SQLException: Parameter index out of range (1 > number of parameters, which is 0).
   	at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:965)
   	at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:898)
   	at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:887)
   	at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:861)
   	at com.mysql.jdbc.PreparedStatement.checkBounds(PreparedStatement.java:3385)
   	at com.mysql.jdbc.PreparedStatement.setInternal(PreparedStatement.java:3370)
   	at com.mysql.jdbc.PreparedStatement.setInternal(PreparedStatement.java:3409)
   	at com.mysql.jdbc.PreparedStatement.setInt(PreparedStatement.java:3360)
   	at com.mysql.jdbc.PreparedStatement.setObject(PreparedStatement.java:3595)
   	at com.mysql.jdbc.JDBC42PreparedStatement.setObject(JDBC42PreparedStatement.java:68)
   	at com.zaxxer.hikari.pool.HikariProxyPreparedStatement.setObject(HikariProxyPreparedStatement.java)
   	at **org.apache.shardingsphere.driver.jdbc.adapter.AbstractPreparedStatementAdapter.lambda$addParameters$0(AbstractPreparedStatementAdapter.java:289)
   	at org.apache.shardingsphere.driver.jdbc.adapter.AbstractPreparedStatementAdapter.replaySetParameter(AbstractPreparedStatementAdapter.java:281)**
   	at org.apache.shardingsphere.driver.jdbc.core.statement.ShardingSpherePreparedStatement.replaySetParameter(ShardingSpherePreparedStatement.java:415)
   	at org.apache.shardingsphere.driver.jdbc.core.statement.ShardingSpherePreparedStatement.replay(ShardingSpherePreparedStatement.java:407)
   	at org.apache.shardingsphere.driver.jdbc.core.statement.ShardingSpherePreparedStatement.cacheStatements(ShardingSpherePreparedStatement.java:403)
   	at org.apache.shardingsphere.driver.jdbc.core.statement.ShardingSpherePreparedStatement.execute(ShardingSpherePreparedStatement.java:297)
   	at org.apache.ibatis.executor.statement.PreparedStatementHandler.update(PreparedStatementHandler.java:47)
   	at org.apache.ibatis.executor.statement.RoutingStatementHandler.update(RoutingStatementHandler.java:74)
   	at org.apache.ibatis.executor.SimpleExecutor.doUpdate(SimpleExecutor.java:50)
   	at org.apache.ibatis.executor.BaseExecutor.update(BaseExecutor.java:117)
   	at org.apache.ibatis.executor.CachingExecutor.update(CachingExecutor.java:76)
   	at org.apache.ibatis.session.defaults.DefaultSqlSession.update(DefaultSqlSession.java:197)
   	at org.apache.ibatis.session.defaults.DefaultSqlSession.insert(DefaultSqlSession.java:184)
   	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
   	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
   	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
   	at java.lang.reflect.Method.invoke(Method.java:498)
   	at org.mybatis.spring.SqlSessionTemplate$SqlSessionInterceptor.invoke(SqlSessionTemplate.java:426)
   	... 45 more
   


-- 
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] fyname edited a comment on issue #13719: No qualifying bean of type 'org.apache.shardingsphere.infra.config.mode.ModeConfiguration'

Posted by GitBox <gi...@apache.org>.
fyname edited a comment on issue #13719:
URL: https://github.com/apache/shardingsphere/issues/13719#issuecomment-976069697


   > ```
   > mybatis:
   >   mapper-locations: classpath:mapper/*.xml
   >   type-aliases-package: com.freesun.shardingsphere.multitenancy.model
   > 
   > spring:
   >   shardingsphere:
   >     mode:
   >       type: Memory
   >     schema:
   >       name: multit-tenant
   >     datasource:
   >       names: aliyun,tmall,taobao
   >       aliyun:
   >         type: com.zaxxer.hikari.HikariDataSource
   >         driver-class-name: com.mysql.jdbc.Driver
   >         jdbc-url: jdbc:mysql://127.0.0.1:3306/aliyun?serverTimezone=UTC&useSSL=false&useUnicode=true&characterEncoding=UTF-8
   >         username: root
   >         password: 123456
   >       taobao:
   >         type: com.zaxxer.hikari.HikariDataSource
   >         driver-class-name: com.mysql.jdbc.Driver
   >         jdbc-url: jdbc:mysql://127.0.0.1:3306/taobao?serverTimezone=UTC&useSSL=false&useUnicode=true&characterEncoding=UTF-8
   >         username: root
   >         password: 123456
   >       tmall:
   >         type: com.zaxxer.hikari.HikariDataSource
   >         driver-class-name: com.mysql.jdbc.Driver
   >         jdbc-url: jdbc:mysql://127.0.0.1:3306/tmall?serverTimezone=UTC&useSSL=false&useUnicode=true&characterEncoding=UTF-8
   >         username: root
   >         password: 123456
   >     rules:
   >       sharding:
   >         tables:
   >           t_order:
   >             actualDataNodes: tmall.tb_order,taobao.tb_order,aliyun.tb_order
   >             keyGenerateStrategy:
   >               column: order_id
   >               keyGeneratorName: snowflake
   >         defaultDatabaseStrategy:
   >           standard:
   >             shardingColumn: merchant
   >             shardingAlgorithmName: db-classbased
   >         defaultTableStrategy:
   >           none:
   > 
   >         shardingAlgorithms:
   >           db-classbased:
   >             type: CLASS_BASED
   >             props:
   >               strategy: standard
   >               algorithmClassName: com.freesun.shardingsphere.multitenancy.spi.DbShardingAlgorithm
   > 
   >         keyGenerators:
   >           snowflake:
   >             type: SNOWFLAKE
   >             props:
   >               worker-id: 123
   > ```
   > 
   > Replace your configuration.
   
   HI 
   
   Custom SPI not called found
   The shardingwehre interface is not introduced, the call is normal, and the data is saved to MySQL
   The SQL exception occurred in the configuration after reference is as follows:
   
   org.springframework.dao.TransientDataAccessResourceException: 
   ### Error updating database.  Cause: java.sql.SQLException: Parameter index out of range (1 > number of parameters, which is 0).
   ### The error may exist in file [D:\workspace\multit-tenant\target\classes\com\freesun\shardingsphere\multitenancy\dao\OrderMapper.xml]
   ### The error may involve com.freesun.shardingsphere.multitenancy.dao.OrderDAO.save-Inline
   ### The error occurred while setting parameters
   ### SQL: insert into tb_order         (             `user_id`,             `order_no`,             `order_time`,             `merchant`         )         values         (             ?,             ?,             ?,             ?         )
   ### Cause: java.sql.SQLException: Parameter index out of range (1 > number of parameters, which is 0).
   ; **Parameter index out of range (1 > number of parameters, which is 0).; nested exception is java.sql.SQLException: Parameter index out of range (1 > number of parameters, which is 0).**
   
   	at org.springframework.jdbc.support.SQLStateSQLExceptionTranslator.doTranslate(SQLStateSQLExceptionTranslator.java:110)
   	at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:70)
   	at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:79)
   	at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:79)
   	at org.mybatis.spring.MyBatisExceptionTranslator.translateExceptionIfPossible(MyBatisExceptionTranslator.java:88)
   	at org.mybatis.spring.SqlSessionTemplate$SqlSessionInterceptor.invoke(SqlSessionTemplate.java:440)
   	at com.sun.proxy.$Proxy203.insert(Unknown Source)
   	at org.mybatis.spring.SqlSessionTemplate.insert(SqlSessionTemplate.java:271)
   	at com.freesun.shardingsphere.multitenancy.dao.OrderDAOImpl.save(OrderDAOImpl.java:20)
   	at com.freesun.shardingsphere.multitenancy.dao.OrderDAOImpl$$FastClassBySpringCGLIB$$4237c205.invoke(<generated>)
   	at org.springframework.cglib.proxy.MethodProxy.invoke(MethodProxy.java:218)
   	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.invokeJoinpoint(CglibAopProxy.java:779)
   	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163)
   	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:750)
   	at org.springframework.dao.support.PersistenceExceptionTranslationInterceptor.invoke(PersistenceExceptionTranslationInterceptor.java:137)
   	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:186)
   	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.proceed(CglibAopProxy.java:750)
   	at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:692)
   	at com.freesun.shardingsphere.multitenancy.dao.OrderDAOImpl$$EnhancerBySpringCGLIB$$1c726bff.save(<generated>)
   	at com.freesun.shardingsphere.multitenancy.service.impl.OrderServiceImpl.save(OrderServiceImpl.java:17)
   	at com.freesun.shardingsphere.multitenancy.OrderSpringBootTests.save(OrderSpringBootTests.java:45)
   	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
   	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
   	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
   	at java.lang.reflect.Method.invoke(Method.java:498)
   	at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:50)
   	at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
   	at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:47)
   	at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:17)
   	at org.springframework.test.context.junit4.statements.RunBeforeTestExecutionCallbacks.evaluate(RunBeforeTestExecutionCallbacks.java:74)
   	at org.springframework.test.context.junit4.statements.RunAfterTestExecutionCallbacks.evaluate(RunAfterTestExecutionCallbacks.java:84)
   	at org.springframework.test.context.junit4.statements.RunBeforeTestMethodCallbacks.evaluate(RunBeforeTestMethodCallbacks.java:75)
   	at org.springframework.test.context.junit4.statements.RunAfterTestMethodCallbacks.evaluate(RunAfterTestMethodCallbacks.java:86)
   	at org.springframework.test.context.junit4.statements.SpringRepeat.evaluate(SpringRepeat.java:84)
   	at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:325)
   	at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.runChild(SpringJUnit4ClassRunner.java:251)
   	at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.runChild(SpringJUnit4ClassRunner.java:97)
   	at org.junit.runners.ParentRunner$3.run(ParentRunner.java:290)
   	at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:71)
   	at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:288)
   	at org.junit.runners.ParentRunner.access$000(ParentRunner.java:58)
   	at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:268)
   	at org.springframework.test.context.junit4.statements.RunBeforeTestClassCallbacks.evaluate(RunBeforeTestClassCallbacks.java:61)
   	at org.springframework.test.context.junit4.statements.RunAfterTestClassCallbacks.evaluate(RunAfterTestClassCallbacks.java:70)
   	at org.junit.runners.ParentRunner.run(ParentRunner.java:363)
   	at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.run(SpringJUnit4ClassRunner.java:190)
   	at org.junit.runner.JUnitCore.run(JUnitCore.java:137)
   	at com.intellij.junit4.JUnit4IdeaTestRunner.startRunnerWithArgs(JUnit4IdeaTestRunner.java:69)
   	at com.intellij.rt.junit.IdeaTestRunner$Repeater.startRunnerWithArgs(IdeaTestRunner.java:33)
   	at com.intellij.rt.junit.JUnitStarter.prepareStreamsAndStart(JUnitStarter.java:221)
   	at com.intellij.rt.junit.JUnitStarter.main(JUnitStarter.java:54)
   Caused by: java.sql.SQLException: Parameter index out of range (1 > number of parameters, which is 0).
   	at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:965)
   	at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:898)
   	at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:887)
   	at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:861)
   	at com.mysql.jdbc.PreparedStatement.checkBounds(PreparedStatement.java:3385)
   	at com.mysql.jdbc.PreparedStatement.setInternal(PreparedStatement.java:3370)
   	at com.mysql.jdbc.PreparedStatement.setInternal(PreparedStatement.java:3409)
   	at com.mysql.jdbc.PreparedStatement.setInt(PreparedStatement.java:3360)
   	at com.mysql.jdbc.PreparedStatement.setObject(PreparedStatement.java:3595)
   	at com.mysql.jdbc.JDBC42PreparedStatement.setObject(JDBC42PreparedStatement.java:68)
   	at com.zaxxer.hikari.pool.HikariProxyPreparedStatement.setObject(HikariProxyPreparedStatement.java)
   	at **org.apache.shardingsphere.driver.jdbc.adapter.AbstractPreparedStatementAdapter.lambda$addParameters$0(AbstractPreparedStatementAdapter.java:289)
   	at org.apache.shardingsphere.driver.jdbc.adapter.AbstractPreparedStatementAdapter.replaySetParameter(AbstractPreparedStatementAdapter.java:281)**
   	at org.apache.shardingsphere.driver.jdbc.core.statement.ShardingSpherePreparedStatement.replaySetParameter(ShardingSpherePreparedStatement.java:415)
   	at org.apache.shardingsphere.driver.jdbc.core.statement.ShardingSpherePreparedStatement.replay(ShardingSpherePreparedStatement.java:407)
   	at org.apache.shardingsphere.driver.jdbc.core.statement.ShardingSpherePreparedStatement.cacheStatements(ShardingSpherePreparedStatement.java:403)
   	at org.apache.shardingsphere.driver.jdbc.core.statement.ShardingSpherePreparedStatement.execute(ShardingSpherePreparedStatement.java:297)
   	at org.apache.ibatis.executor.statement.PreparedStatementHandler.update(PreparedStatementHandler.java:47)
   	at org.apache.ibatis.executor.statement.RoutingStatementHandler.update(RoutingStatementHandler.java:74)
   	at org.apache.ibatis.executor.SimpleExecutor.doUpdate(SimpleExecutor.java:50)
   	at org.apache.ibatis.executor.BaseExecutor.update(BaseExecutor.java:117)
   	at org.apache.ibatis.executor.CachingExecutor.update(CachingExecutor.java:76)
   	at org.apache.ibatis.session.defaults.DefaultSqlSession.update(DefaultSqlSession.java:197)
   	at org.apache.ibatis.session.defaults.DefaultSqlSession.insert(DefaultSqlSession.java:184)
   	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
   	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
   	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
   	at java.lang.reflect.Method.invoke(Method.java:498)
   	at org.mybatis.spring.SqlSessionTemplate$SqlSessionInterceptor.invoke(SqlSessionTemplate.java:426)
   	... 45 more
   
   github: https://github.com/fyname/multit-tenant.git


-- 
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] fyname closed issue #13719: No qualifying bean of type 'org.apache.shardingsphere.infra.config.mode.ModeConfiguration'

Posted by GitBox <gi...@apache.org>.
fyname closed issue #13719:
URL: https://github.com/apache/shardingsphere/issues/13719


   


-- 
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] fyname commented on issue #13719: No qualifying bean of type 'org.apache.shardingsphere.infra.config.mode.ModeConfiguration'

Posted by GitBox <gi...@apache.org>.
fyname commented on issue #13719:
URL: https://github.com/apache/shardingsphere/issues/13719#issuecomment-975004787


   > @fyname You can change bootstrap.yml to application.yml and remove @activeprofiles("sharding") in OrderSpringBootTests.calss.
   
   hello
   update bootstrap.yml to application.yml and remove @activeprofiles("sharding") in OrderSpringBootTests
   
   New mistakes appear:
   Caused by: org.apache.shardingsphere.spi.exception.ServiceProviderNotFoundException: No implementation class load from SPI org.apache.shardingsphere.sharding.spi.ShardingAlgorithm with type null.
   at org.apache.shardingsphere.spi.typed.TypedSPIRegistry.getRegisteredService(TypedSPIRegistry.java:76)
   at org.apache.shardingsphere.spring.boot.registry.AbstractAlgorithmProvidedBeanRegistry.lambda$registerBean$2(AbstractAlgorithmProvidedBeanRegistry.java:78)
   at java.util.LinkedHashMap.forEach(LinkedHashMap.java:684)
   at org.apache.shardingsphere.spring.boot.registry.AbstractAlgorithmProvidedBeanRegistry.registerBean(AbstractAlgorithmProvidedBeanRegistry.java:77)
   at org.apache.shardingsphere.sharding.spring.boot.algorithm.ShardingAlgorithmProvidedBeanRegistry.postProcessBeanDefinitionRegistry(ShardingAlgorithmProvidedBeanRegistry.java:38)
   at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanDefinitionRegistryPostProcessors(PostProcessorRegistrationDelegate.java:311)
   at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanFactoryPostProcessors(PostProcessorRegistrationDelegate.java:142)
   at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:746)
   at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:564)
   at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:771)
   at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:763)
   at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:438)
   at org.springframework.boot.SpringApplication.run(SpringApplication.java:339)
   at org.springframework.boot.test.context.SpringBootContextLoader.loadContext(SpringBootContextLoader.java:123)
   at org.springframework.test.context.cache.DefaultCacheAwareContextLoaderDelegate.loadContextInternal(DefaultCacheAwareContextLoaderDelegate.java:99)
   at org.springframework.test.context.cache.DefaultCacheAwareContextLoaderDelegate.loadContext(DefaultCacheAwareContextLoaderDelegate.java:124)
   
   github: https://github.com/fyname/multit-tenant.git


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