Reputation: 5543
During the project building, i received an error:
Could not load JDBC driver class [com.mysql.jdbc.Driver]
I have jdbc connector attached to my project (mysql-connector-java-5.1.18-bin.jar) and i specified in 'database.properties.svn-base' that i'm using MySQL. And the service is running. And I placed this 'jar' int webapp/web-inf/lib/ directory.
But i've noticed, that system can't add this class into Maven dependencies.
How could i resolve this problem?
Upvotes: 0
Views: 4021
Reputation: 120791
Add this to your pom, and remove the jar that you have added by hand
<dependency>
<groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId>
<version>5.1.6</version>
</dependency>
Maven controlles the libs in your target web application lib folder, not the other way arround.
Upvotes: 1