Skip to Main Content

Infrastructure Software

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Problem to configure JDBC Pool Connection.

Cezar ApulchroAug 10 2024

I'm initiating my learned in the glassfish server, I've an web app in java with mysql db then I'm trying to create an jdbc connection pool. step by step to create the connection.

JDBC Resource:

  • JNDI Name: jdbc/MedicalDS

  • POOL Name: MedicalDS

JDBC Connection Pool:

  • Pool Name: MedicalDS

  • Resource Type: javax.sql.ConnectionPoolDataSource

  • Datasource Classname: com.mysql.jdbc.jdbc2.optional.MysqlConnectionPoolDataSource

JDBC Connection Pool Properties:

  • password: mypswd

  • databaseName: db_medical

  • serverName: ipaddress

  • user: root

  • portNumber: 3306

  • URL: jdbc:mysql://186.202.57.170:3306/db_medical?useSSL=true?zeroDateTimeBehavior=CONVERT_TO_NULL

  • Uri:jdbc:mysql://186.202.57.170:3306/db_medical?useSSL=true?zeroDateTimeBehavior=CONVERT_TO_NULL

But when I ping to test the configuration I'm receiving an error "Ping Connection Pool failed for org.glassfish.resourcebase.resources.api.PoolInfo@d07ba71f[jndiName=MedicalDS, applicationName=null, moduleName=null]. Class name is wrong or classpath is not set for : com.mysql.jdbc.jdbc2.optional.MysqlConnectionPoolDataSource Please check the server.log for more details."
Thanks in advanced.

Comments
Post Details
Added on Aug 10 2024
0 comments
482 views