0
currently I am following this link
to solve
Caused by: javax.resource.ResourceException: Class name is wrong or classpath is not set for : com.mysql.cj.jdbc.MysqlDataSource
So, I added mysql-connector-java-5.1.46.jar to my glassfish installation as shown in the screenshot below:
Glassfish installation directory
After a restart of Glassfish I my .war still does not deploy with the same error message (stacktrace below)
Caused by: javax.resource.ResourceException: Class name is wrong or classpath is not set for : com.mysql.cj.jdbc.MysqlDataSource
at com.sun.gjc.common.DataSourceObjectBuilder.getDataSourceObject(DataSourceObjectBuilder.java:278)
at com.sun.gjc.common.DataSourceObjectBuilder.constructDataSourceObject(DataSourceObjectBuilder.java:117)
at com.sun.gjc.spi.ManagedConnectionFactoryImpl.getDataSource(ManagedConnectionFactoryImpl.java:1383)
at com.sun.gjc.spi.DSManagedConnectionFactory.getDataSource(DSManagedConnectionFactory.java:163)
at com.sun.gjc.spi.DSManagedConnectionFactory.createManagedConnection(DSManagedConnectionFactory.java:102)
at com.sun.enterprise.resource.allocator.LocalTxConnectorAllocator.createResource(LocalTxConnectorAllocator.java:87)
Does anyone know how to solve the problem? Thank you.
Great! Be sure to accept this as the correct Answer. – HazardousGlitch – 2019-04-04T09:15:55.517