問(wèn)題描述: ### Error querying database. Cause: org.apache.ibatis.transaction.TransactionException: Error configuring AutoCommit. Your driver may not support getAutoCommit() or setAutoCommit(). Requested setting: false. Cause: com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: The last packet successfully received from the server was 57,193,128 milliseconds ago. The last packet sent successfully to the server was 57,193,128 milliseconds ago. is longer than the server configured value of 'wait_timeout'. You should consider either expiring and/or testing connection validity before use in your application, increasing the server configured values for client timeouts, or using the Connector/J connection property 'autoReconnect=true' to avoid this problem. To solve this problem you need to set the poolPingQuery and poolPingEnabled properties in the iBatis config file. For example, see lines 13-14 in code below.
sql消耗越小越好。 鏈接地址: http://my.oschina.net/yygh/blog/261047?p=1 |
|
來(lái)自: 軟件團(tuán)隊(duì)頭目 > 《Web應(yīng)用》