0

I am having some troubles to connect my multimodule maven project to proxysql. When i connect to two different environments - one with mysql 8 and other with mysql 5, the app is connecting fine and working fine. When I connect to the proxy with mysql-connector via cj driver is throwing:

java.sql.SQLException: Unknown system variable 'query_cache_size'

Tried to change to mariadb and it throws:

 java.sql.SQLException: Unknown system variable 'tx_isolation'

This happens with the latest versions of mysql-connector and mariadb client.

When i created a simple maven module(non-spring) via ConnectionFactory is connecting! (mariadb client 2.7.0 or lower) When i created a simple Spring app and tried to connect - same errors. Does anyone could help here :( I am using mybatis as ORM. Maybe it's the jdbc version inside of the spring or the mybatis one.

OneCricketeer
  • 179,855
  • 19
  • 132
  • 245
  • Does this answer your question? [java.sql.SQLException: Unknown system variable 'query\_cache\_size'](https://stackoverflow.com/questions/49984267/java-sql-sqlexception-unknown-system-variable-query-cache-size) – pringi Mar 02 '22 at 09:26
  • actually no, you need to "lie" the proxy and set it in the mysqlcnf.yaml that "mysql_server_version=8.0.27" or above 5 – user18336439 Mar 07 '22 at 22:26

0 Answers0