" async="async"> ', { cookie_domain: 'auto', cookie_flags: 'max-age=0;domain=.tistory.com', cookie_expires: 7 * 24 * 60 * 60 // 7 days, in seconds }); The new driver class is 'com.mysql.cj.jdbc.Driver'. MySQL 에러, MySQL 버전 확인 :: 일단

JDBC로 MySQL 연동중 에러가 발생한다.

Loading claLoading class 'com.mysql.jdbc.Driver'. This is deprecated. The new driver class is 'com.mysql.cj.jdbc.Driver'.

 

에러 메시지도 아주 친절하다.

로딩하고 있는 클래스는 com.mysql.jdbc.Driver이다. 이 것은 deprecated 하다.

새로운 드라이버 클래스는 com.mysql.cj.jdbc.Driver이다.

 

결론은 JDBC 연결할 때 드라이버 정보를 com.mysql.jdbc.Driver에서 com.mysql.cj.jdbc.Driver로 바꿔주면 된다.

 

현재 JDBC 커넥터 라이브러리로 mysql-connector-java-8.0.16을 사용하고 있다. 클래스가 바뀐 것이다.

MySQL 버전 확인;

 

참고 : https://dev.mysql.com/doc/connector-j/8.0/en/connector-j-usagenotes-connect-drivermanager.html

+ Recent posts