I have a very strange issue; MYSQL max_allowed_packet is already set as 32MB;
max_allowed_packet 33554432
And below is my
JDBC code to get MYSQL connection:
String url = "jdbc:mysql://" + server + ":" + port;
if (database != null)
url += "/" + database;
url = url + "?user=" + username + "&password=" + password;
connection = DriverManager.getConnection(url);
But it still throw out exception that max_allowed_packet is too small;
com.mysql.jdbc.PacketTooBigException: Packet for query is too large (4739923 > 1048576). You can change this value on the server by setting the max_allowed_packet' variable.
Can someone know why this happen? or is there any other place may cause this issue too?
Thanks!