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 2020/10/28 12:10:57 UTC

[GitHub] [shardingsphere] maxlange opened a new issue #7947: java.lang.UnsupportedOperationException: Cannot support database type 'MySQL'

maxlange opened a new issue #7947:
URL: https://github.com/apache/shardingsphere/issues/7947


     At first,i would show the exception stack information 
   `java.lang.UnsupportedOperationException: Cannot support database type 'MySQL'
   	at org.apache.shardingsphere.sql.parser.core.parser.SQLParserFactory.newInstance(SQLParserFactory.java:55)
   	at org.apache.shardingsphere.sql.parser.core.parser.SQLParserExecutor.towPhaseParse(SQLParserExecutor.java:55)
   	at org.apache.shardingsphere.sql.parser.core.parser.SQLParserExecutor.execute(SQLParserExecutor.java:47)
   	at org.apache.shardingsphere.sql.parser.SQLParserEngine.parse0(SQLParserEngine.java:79)
   	at org.apache.shardingsphere.sql.parser.SQLParserEngine.parse(SQLParserEngine.java:61)
   	at org.apache.shardingsphere.shardingjdbc.jdbc.core.statement.metadata.ShardingParameterMetaData.getParameterCount(ShardingParameterMetaData.java:36)
   	at io.seata.rm.datasource.AbstractPreparedStatementProxy.initParameterHolder(AbstractPreparedStatementProxy.java:56)
   	at io.seata.rm.datasource.AbstractPreparedStatementProxy.<init>(AbstractPreparedStatementProxy.java:74)
   	at io.seata.rm.datasource.PreparedStatementProxy.<init>(PreparedStatementProxy.java:49)
   	at io.seata.rm.datasource.AbstractConnectionProxy.prepareStatement(AbstractConnectionProxy.java:122)
   	at io.seata.rm.datasource.AbstractConnectionProxy.prepareStatement(AbstractConnectionProxy.java:120)
   	at org.apache.ibatis.executor.statement.PreparedStatementHandler.instantiateStatement(PreparedStatementHandler.java:86)
   	at org.apache.ibatis.executor.statement.BaseStatementHandler.prepare(BaseStatementHandler.java:88)
   	at org.apache.ibatis.executor.statement.RoutingStatementHandler.prepare(RoutingStatementHandler.java:59)
   	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:497)
   	at org.apache.ibatis.plugin.Invocation.proceed(Invocation.java:49)
   	at com.baomidou.mybatisplus.extension.plugins.PaginationInterceptor.intercept(PaginationInterceptor.java:188)
   	at org.apache.ibatis.plugin.Plugin.invoke(Plugin.java:61)
   	at com.sun.proxy.$Proxy253.prepare(Unknown Source)
   	at com.baomidou.mybatisplus.core.executor.MybatisSimpleExecutor.prepareStatement(MybatisSimpleExecutor.java:92)
   	at com.baomidou.mybatisplus.core.executor.MybatisSimpleExecutor.doQuery(MybatisSimpleExecutor.java:66)
   	at org.apache.ibatis.executor.BaseExecutor.queryFromDatabase(BaseExecutor.java:324)
   	at org.apache.ibatis.executor.BaseExecutor.query(BaseExecutor.java:156)
   	at com.baomidou.mybatisplus.core.executor.MybatisCachingExecutor.query(MybatisCachingExecutor.java:134)
   	at com.baomidou.mybatisplus.core.executor.MybatisCachingExecutor.query(MybatisCachingExecutor.java:90)
   	at org.apache.ibatis.session.defaults.DefaultSqlSession.selectList(DefaultSqlSession.java:147)
   	at org.apache.ibatis.session.defaults.DefaultSqlSession.selectList(DefaultSqlSession.java:140)
   	at org.apache.ibatis.session.defaults.DefaultSqlSession.selectOne(DefaultSqlSession.java:76)
   	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:497)
   	at org.mybatis.spring.SqlSessionTemplate$SqlSessionInterceptor.invoke(SqlSessionTemplate.java:426)
   	at com.sun.proxy.$Proxy180.selectOne(Unknown Source)
   	at org.mybatis.spring.SqlSessionTemplate.selectOne(SqlSessionTemplate.java:159)
   	at com.baomidou.mybatisplus.core.override.MybatisMapperMethod.execute(MybatisMapperMethod.java:108)
   	at com.baomidou.mybatisplus.core.override.MybatisMapperProxy.invoke(MybatisMapperProxy.java:96)
   	at com.sun.proxy.$Proxy182.selectOne(Unknown Source)
   	at com.baomidou.mybatisplus.extension.conditions.query.ChainQuery.one(ChainQuery.java:48)
   	at com.enation.app.javashop.service.payment.impl.PaymentBillManagerImpl.getBySubSnAndServiceType(PaymentBillManagerImpl.java:152)
   	at com.enation.app.javashop.service.payment.impl.PaymentBillManagerImpl.add(PaymentBillManagerImpl.java:68)
   	at com.enation.app.javashop.service.payment.impl.PaymentBillManagerImpl$$FastClassBySpringCGLIB$$c1dabe73.invoke(<generated>)
   	at org.springframework.cglib.proxy.MethodProxy.invoke(MethodProxy.java:204)
   	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.invokeJoinpoint(CglibAopProxy.java:747)
   	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163)
   	at org.springframework.transaction.interceptor.TransactionInterceptor$$Lambda$1828/1089505410.proceedWithInvocation(Unknown Source)
   	at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:294)
   	at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:98)
   	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:185)
   	at com.enation.app.javashop.framework.transaction.SeataInterceptor$1.execute(SeataInterceptor.java:98)
   	at io.seata.tm.api.TransactionalTemplate.execute(TransactionalTemplate.java:64)
   	at com.enation.app.javashop.framework.transaction.SeataInterceptor.handleGlobalTransaction(SeataInterceptor.java:95)
   	at com.enation.app.javashop.framework.transaction.SeataInterceptor.invoke(SeataInterceptor.java:72)
   	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:185)
   	at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:689)
   	at com.enation.app.javashop.service.payment.impl.PaymentBillManagerImpl$$EnhancerBySpringCGLIB$$45d43de9.add(<generated>)
   	at com.enation.app.javashop.service.payment.impl.PaymentManagerImpl.pay(PaymentManagerImpl.java:143)
   	at com.enation.app.javashop.api.client.PaymentClientController.pay(PaymentClientController.java:38)
   	at com.enation.app.javashop.api.client.PaymentClientController$$FastClassBySpringCGLIB$$b11ee2d8.invoke(<generated>)
   	at org.springframework.cglib.proxy.MethodProxy.invoke(MethodProxy.java:204)
   	at org.springframework.aop.framework.CglibAopProxy$CglibMethodInvocation.invokeJoinpoint(CglibAopProxy.java:747)
   	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:163)
   	at org.springframework.validation.beanvalidation.MethodValidationInterceptor.invoke(MethodValidationInterceptor.java:112)
   	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:185)
   	at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:689)
   	at com.enation.app.javashop.api.client.PaymentClientController$$EnhancerBySpringCGLIB$$3a469be5.pay(<generated>)
   	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:497)
   	at org.springframework.web.method.support.InvocableHandlerMethod.doInvoke(InvocableHandlerMethod.java:209)
   	at org.springframework.web.method.support.InvocableHandlerMethod.invokeForRequest(InvocableHandlerMethod.java:136)
   	at org.springframework.web.servlet.mvc.method.annotation.ServletInvocableHandlerMethod.invokeAndHandle(ServletInvocableHandlerMethod.java:102)
   	at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.invokeHandlerMethod(RequestMappingHandlerAdapter.java:877)
   	at org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter.handleInternal(RequestMappingHandlerAdapter.java:783)
   	at org.springframework.web.servlet.mvc.method.AbstractHandlerMethodAdapter.handle(AbstractHandlerMethodAdapter.java:87)
   	at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:991)
   	at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:925)
   	at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:974)
   	at org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:877)
   	at javax.servlet.http.HttpServlet.service(HttpServlet.java:661)
   	at org.springframework.web.servlet.FrameworkServlet.service(FrameworkServlet.java:851)
   	at javax.servlet.http.HttpServlet.service(HttpServlet.java:742)
   	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231)
   	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
   	at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
   	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
   	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
   	at org.springframework.boot.actuate.metrics.web.servlet.WebMvcMetricsFilter.filterAndRecordMetrics(WebMvcMetricsFilter.java:158)
   	at org.springframework.boot.actuate.metrics.web.servlet.WebMvcMetricsFilter.filterAndRecordMetrics(WebMvcMetricsFilter.java:126)
   	at org.springframework.boot.actuate.metrics.web.servlet.WebMvcMetricsFilter.doFilterInternal(WebMvcMetricsFilter.java:111)
   	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
   	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
   	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
   	at com.enation.app.javashop.framework.parameter.ParameterFilter.doFilter(ParameterFilter.java:29)
   	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
   	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
   	at org.springframework.boot.actuate.web.trace.servlet.HttpTraceFilter.doFilterInternal(HttpTraceFilter.java:84)
   	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
   	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
   	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
   	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:320)
   	at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:127)
   	at org.springframework.security.web.access.intercept.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:91)
   	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334)
   	at org.springframework.security.web.access.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:119)
   	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334)
   	at org.springframework.security.web.session.SessionManagementFilter.doFilter(SessionManagementFilter.java:137)
   	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334)
   	at org.springframework.security.web.authentication.AnonymousAuthenticationFilter.doFilter(AnonymousAuthenticationFilter.java:111)
   	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334)
   	at org.springframework.security.web.servletapi.SecurityContextHolderAwareRequestFilter.doFilter(SecurityContextHolderAwareRequestFilter.java:170)
   	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334)
   	at org.springframework.security.web.savedrequest.RequestCacheAwareFilter.doFilter(RequestCacheAwareFilter.java:63)
   	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334)
   	at com.enation.app.javashop.framework.security.TokenAuthenticationFilter.doFilter(TokenAuthenticationFilter.java:48)
   	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334)
   	at org.springframework.security.web.authentication.logout.LogoutFilter.doFilter(LogoutFilter.java:116)
   	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334)
   	at org.springframework.web.filter.CorsFilter.doFilterInternal(CorsFilter.java:96)
   	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
   	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334)
   	at org.springframework.security.web.header.HeaderWriterFilter.doFilterInternal(HeaderWriterFilter.java:66)
   	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
   	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334)
   	at org.springframework.security.web.context.SecurityContextPersistenceFilter.doFilter(SecurityContextPersistenceFilter.java:105)
   	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334)
   	at org.springframework.security.web.context.request.async.WebAsyncManagerIntegrationFilter.doFilterInternal(WebAsyncManagerIntegrationFilter.java:56)
   	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
   	at org.springframework.security.web.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:334)
   	at org.springframework.security.web.FilterChainProxy.doFilterInternal(FilterChainProxy.java:215)
   	at org.springframework.security.web.FilterChainProxy.doFilter(FilterChainProxy.java:178)
   	at org.springframework.web.filter.DelegatingFilterProxy.invokeDelegate(DelegatingFilterProxy.java:357)
   	at org.springframework.web.filter.DelegatingFilterProxy.doFilter(DelegatingFilterProxy.java:270)
   	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
   	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
   	at org.springframework.web.filter.RequestContextFilter.doFilterInternal(RequestContextFilter.java:99)
   	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
   	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
   	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
   	at org.springframework.web.filter.HttpPutFormContentFilter.doFilterInternal(HttpPutFormContentFilter.java:109)
   	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
   	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
   	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
   	at org.springframework.web.filter.HiddenHttpMethodFilter.doFilterInternal(HiddenHttpMethodFilter.java:81)
   	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
   	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
   	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
   	at org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:200)
   	at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
   	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
   	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
   	at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:198)
   	at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96)
   	at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:496)
   	at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:140)
   	at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:81)
   	at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:87)
   	at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:342)
   	at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:803)
   	at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66)
   	at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:790)
   	at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1459)
   	at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
   	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
   	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
   	at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
   	at java.lang.Thread.run(Thread.java:745)`
     When i use shardingsphere in spring cloud project ,the version is 4.1.0,use maven build,like this
   `<dependency>
   	<groupId>org.apache.shardingsphere</groupId>
   	<artifactId>sharding-jdbc-spring-boot-starter</artifactId>
   	<version>4.1.0</version>
   </dependency>`
     The configuration use yaml file,like this
   `spring:
     profiles:
     shardingsphere:
       props:
         sql:
           show: true
       sharding:
         default-data-source-name: ds0
       datasource:
         names: ds0
         ds0:
           type: com.alibaba.druid.pool.DruidDataSource
           driver-class-name: com.mysql.jdbc.Driver
           url: jdbc:mysql://x.x.x.x:3306/trade?useUnicode=true&characterEncoding=utf8&autoReconnect=true
           username: xxx
           password: xxx`
       So when i use mybatis-plus to query data from mysql database,sometimes this kind of problem occurs.I try to trace the source code,in this class:NewInstanceServiceLoader#newServiceInstances(final Class<T> service),like this 
   `public static <T> Collection<T> newServiceInstances(final Class<T> service) {
           Collection<T> result = new LinkedList<>();
           if (null == SERVICE_MAP.get(service)) {
               return result;
           }
           for (Class<?> each : SERVICE_MAP.get(service)) {
               result.add((T) each.newInstance());
           }
           return result;
       }`
     If the parameter service is :"interface org.apache.shardingsphere.underlying.common.hook.RootInvokeHook" used,the SERVICE_MAP.get(service) is null ,so retrun the empty collection.At last,in this class :SQLParserFactory#newInstance(final String databaseTypeName, final String sql) will throw the exception,like this:
   `public static SQLParser newInstance(final String databaseTypeName, final String sql) {
           for (SQLParserConfiguration each : NewInstanceServiceLoader.newServiceInstances(SQLParserConfiguration.class)) {
               if (each.getDatabaseTypeName().equals(databaseTypeName)) {
                   return createSQLParser(sql, each);
               }
           }
           throw new UnsupportedOperationException(String.format("Cannot support database type '%s'", databaseTypeName));
       }`
     So I want to know if there is a problem with my configuration? There are still other issues. I have seen similar issues in other guys, but none of them can solve my problem. This service "interface 
    org.apache.shardingsphere.underlying.common.hook.RootInvokeHook" is not registered and I am very confused, please help me.


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

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



[GitHub] [shardingsphere] gitchong commented on issue #7947: java.lang.UnsupportedOperationException: Cannot support database type 'MySQL'

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


   I also meet this problem without seata when application run in linux system tomcat, in window dev environment is ok. thought debug, find cant get SQLParserConfiguration load implement, and the jar shardingsphere-sql-parser-mysql-4.1.1.jar is on the classpath.  now I dont have litter idea about this.


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

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



[GitHub] [shardingsphere] terrymanu closed issue #7947: java.lang.UnsupportedOperationException: Cannot support database type 'MySQL'

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


   


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

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



[GitHub] [shardingsphere] gitchong commented on issue #7947: java.lang.UnsupportedOperationException: Cannot support database type 'MySQL'

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


   when I  do this which  when application started, load SQLParserConfiguration manual , the problem resolved. but I dont known why it cant load in tomcat. run with jar of springboot project is ok.run with war in tomcat is wrong.
   
   @Component
   @Slf4j
   public class ApplicationStartedListener implements ApplicationListener<ApplicationStartedEvent> {
   	@Override
   	public void onApplicationEvent(ApplicationStartedEvent applicationStartedEvent) {
   		onApplicationStarted(applicationStartedEvent);
   	}
   
   	@SneakyThrows
   	private void onApplicationStarted(ApplicationStartedEvent event) {
   		String applicationName = event.getApplicationContext().getApplicationName();
   		log.info("应用【{}】已启动....", applicationName);
   		NewInstanceServiceLoader.register(SQLParserConfiguration.class);
   		log.info("已加载{}", "SQLParserConfiguration");
   	}
   }


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

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



[GitHub] [shardingsphere] avalon5666 commented on issue #7947: java.lang.UnsupportedOperationException: Cannot support database type 'MySQL'

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


   Can you provider the configuration and the sql when exception threw?


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

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



[GitHub] [shardingsphere] maxlange commented on issue #7947: java.lang.UnsupportedOperationException: Cannot support database type 'MySQL'

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


   > Is it inevitable? Confirm that the shardingsphere-sql-parser-mysql jar exists
   
   the jar is exists


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

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



[GitHub] [shardingsphere] kimmking commented on issue #7947: java.lang.UnsupportedOperationException: Cannot support database type 'MySQL'

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


   > I also met this problem, my local test is good and have this problem in my test environment.
   > And I used java8 lambda parallelStream(), I thought it might be a bug about multithreading.
   > 
   > Yes, I changed parallelStream() to stream(), it works fine.
   
   In your special case, we have fixed in 5.0.0 with a synchonized creation of ParserEngine.
   
   But this post show an error maybe from mybatis-plus or seata.


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

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



[GitHub] [shardingsphere] maxlange commented on issue #7947: java.lang.UnsupportedOperationException: Cannot support database type 'MySQL'

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


   > Can you provider the configuration and the sql when exception threw?
   
   excute SQLParserFactory#newInstance(final String databaseTypeName, final String sql),the first parameter databaseType="MySQL",the second parameter sql="SELECT  bill_id,sub_sn,bill_sn,return_trade_no,is_pay,service_type,payment_name,pay_config,trade_price,payment_plugin_id  FROM es_payment_bill WHERE (sub_sn = ? AND service_type = ?)",Is there any configuration needed?The configuration of the shardingsphere is written in the yaml file.like this:
   
   > spring:
     profiles:
     shardingsphere:
       props:
         sql:
           show: true
       sharding:
         default-data-source-name: ds0
       datasource:
         names: ds0
         ds0:
           type: com.alibaba.druid.pool.DruidDataSource
           driver-class-name: com.mysql.jdbc.Driver
           url: jdbc:mysql://xxx:3306/trade?useUnicode=true&characterEncoding=utf8&autoReconnect=true
           username: xxx
           password: xxx


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

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



[GitHub] [shardingsphere] maxlange commented on issue #7947: java.lang.UnsupportedOperationException: Cannot support database type 'MySQL'

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


   Has anyone encountered and solved this problem? Now when i am testing locally, i will get an error when i query the database, which is crazy.


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

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



[GitHub] [shardingsphere] avalon5666 commented on issue #7947: java.lang.UnsupportedOperationException: Cannot support database type 'MySQL'

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


   Is it inevitable? Confirm that the shardingsphere-sql-parser-mysql jar exists


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

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



[GitHub] [shardingsphere] avalon5666 commented on issue #7947: java.lang.UnsupportedOperationException: Cannot support database type 'MySQL'

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


   Try a new version of java environment


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

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



[GitHub] [shardingsphere] linyuliang commented on issue #7947: java.lang.UnsupportedOperationException: Cannot support database type 'MySQL'

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


   I also met this problem, my local test is good and have this problem in my test environment. 
   And I used java8 lambda parallelStream(), I thought it might be a bug about multithreading.
   


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

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



[GitHub] [shardingsphere] linyuliang edited a comment on issue #7947: java.lang.UnsupportedOperationException: Cannot support database type 'MySQL'

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


   I also met this problem, my local test is good and have this problem in my test environment. 
   And I used java8 lambda parallelStream(), I thought it might be a bug about multithreading.
   
   Yes, I changed parallelStream() to stream(), it works fine.
   


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

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



[GitHub] [shardingsphere] terrymanu commented on issue #7947: java.lang.UnsupportedOperationException: Cannot support database type 'MySQL'

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


   No response


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

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



[GitHub] [shardingsphere] kimmking commented on issue #7947: java.lang.UnsupportedOperationException: Cannot support database type 'MySQL'

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


   Could you remove mybatis-plus and try again?


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

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