Total Pageviews

2017/12/10

[DBCP2] [DB2] java.lang.AbstractMethodError: com.ibm.db2.jcc.t4.b.isValid(I)Z

Problem
I am using DBCP2 as my third party library to do connection pool.


But as I try to get connection it throws exception:
java.lang.AbstractMethodError: com.ibm.db2.jcc.t4.b.isValid(I)Z


How-To

Owing to the isValid method was added in JDBC 4.0. I need to change IBM DB2 class from db2jcc.jar (JDBC 3.0) to db2jcc4.jar (JDBC 4.0), then this problem will be solved.


Reference

[1] https://stackoverflow.com/questions/37193965/java-lang-abstractmethoderror-com-ibm-db2-jcc-t4-b-isvalidiz

No comments: