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/05/18 10:45:08 UTC

[GitHub] [shardingsphere] zscxst opened a new issue #5674: MySQL Connector/J 8.X Above return Unknown system variable 'query_cache_size'

zscxst opened a new issue #5674:
URL: https://github.com/apache/shardingsphere/issues/5674


   ## Bug Report
   
   **For English only**, other languages will not accept.
   
   Before report a bug, make sure you have:
   
   - Searched open and closed [GitHub issues](https://github.com/apache/shardingsphere/issues).
   - Read documentation: [ShardingSphere Doc](https://shardingsphere.apache.org/document/current/en/overview).
   
   Please pay attention on issues you submitted, because we maybe need more details. 
   If no response **more than 7 days** and we cannot reproduce it on current information, we will **close it**.
   
   Please answer these questions before submitting your issue. Thanks!
   
   ### Which version of ShardingSphere did you use?
   4.1.0
   
   ### Which project did you use? ShardingSphere-JDBC or ShardingSphere-Proxy?
   ShardingSphere-Proxy
   
   ### Expected behavior
   MySQL Server is 8.0.20
   MySQL Connector/J 8.X Above version connection success
   
   ### Actual behavior
   java.sql.SQLException: Unknown system variable 'query_cache_size'
   
   ### Reason analyze (If you can)
   [https://github.com/apache/shardingsphere/blob/master/shardingsphere-db-protocol/shardingsphere-db-protocol-mysql/src/main/java/org/apache/shardingsphere/db/protocol/mysql/constant/MySQLServerInfo.java](url) file constant SERVER_VERSION.This constant is returned by the handshake protocol. In java client jar file com.mysql.cj.NativeSession will determine the version number of the server.Code is:
   if (!versionMeetsMinimum(8, 0, 3)) {
        queryBuf.append(", @@query_cache_size AS query_cache_size");
         queryBuf.append(", @@query_cache_type AS query_cache_type");
   }
   But mysql server 8 abandon ‘query_cache_size’
   
   ### Steps to reproduce the behavior, such as: SQL to execute, sharding rule configuration, when exception occur etc.
   Mysql server 8.0.20
   
   Java client maven import
   ```xml
   <dependency>
       <groupId>mysql</groupId>
       <artifactId>mysql-connector-java</artifactId>
       <version>8.0.20</version>
   </dependency>
   ```
   
   ### 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.

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



[GitHub] [shardingsphere] cherrylzhao closed issue #5674: MySQL Connector/J 8.X Above return Unknown system variable 'query_cache_size'

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


   


----------------------------------------------------------------
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] little-liang commented on issue #5674: MySQL Connector/J 8.X Above return Unknown system variable 'query_cache_size'

Posted by GitBox <gi...@apache.org>.
little-liang commented on issue #5674:
URL: https://github.com/apache/shardingsphere/issues/5674#issuecomment-630172484


   ask common


----------------------------------------------------------------
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] zscxst commented on issue #5674: MySQL Connector/J 8.X Above return Unknown system variable 'query_cache_size'

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


   > duplicate with #3097
   
   There can be a default version number, but I suggest that you can configure the version number. 


----------------------------------------------------------------
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] cherrylzhao commented on issue #5674: MySQL Connector/J 8.X Above return Unknown system variable 'query_cache_size'

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


   fix at #5720 


----------------------------------------------------------------
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] cherrylzhao commented on issue #5674: MySQL Connector/J 8.X Above return Unknown system variable 'query_cache_size'

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


   duplicate with #3097 


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