How can I solve this exception:
Exception in thread "main" java.lang.AbstractMethodError: com.mysql.jdbc.Connection.isValid(I)Z
at org.apache.commons.dbcp2.DelegatingConnection.isValid(DelegatingConnection.java:914)
...
I read that this error is something about libraries/ jdk but I can't find a good way to solve it. I need some help from you. Thank you!
这意味着您的mysql jdbc驱动程序未实现jre 6中添加的jdbc方法,例如isValid 。
如果提供验证查询,则可以避免升级驱动程序。
我将JDBC驱动程序jar文件升级到mysql-connector-java-6.0.2,并解决了这个问题。
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.