【WebLogic】WebLogic 14c MySQL JDBC-Pool Driver

在 WebLogic 14c (14.1.1.0.0)控制台配置MySQL数据源,如果选择的数据库驱动为:

com.mysql.jdbc.Driver

在数据源的 Target 服务运行时,会在服务日志里面打印如下的提示信息:

Loading class `com.mysql.jdbc.Driver'. This is deprecated. The new driver class is `com.mysql.cj.jdbc.Driver'. The driver is automatically registered via the SPI and manual loading of the driver class is generally unnecessary.

<2023-5-29 上午11时56分00,205秒 CST> <Notice> <Security> <BEA-090947> <Security post-initializing using security realm: myrealm> 
<2023-5-29 上午11时56分02,358秒 CST> <Notice> <Security> <BEA-090082> <Security initialized using administrative security realm: myrealm> 
<2023-5-29 上午11时56分02,835秒 CST> <Notice> <JMX> <BEA-149512> <JMX Connector Server started at service:jmx:iiop://192.168.223.199:17010/jndi/weblogic.management.mbeanservers.runtime.> 
<2023-5-29 上午11时56分04,214秒 CST> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to STANDBY.> 
<2023-5-29 上午11时56分04,215秒 CST> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to STARTING.> 
<2023-5-29 上午11时56分04,260秒 CST> <Notice> <Log Management> <BEA-170036> <The Logging monitoring service timer has started to check for logged message counts every 30 seconds.> 
<2023-5-29 上午11时56分04,339秒 CST> <Notice> <Security> <BEA-090171> <Loading the identity certificate and private key stored under the alias DemoIdentity from the jks keystore file /app/domains/wls14cdomain/security/DemoIdentity.jks.> 
<2023-5-29 上午11时56分04,343秒 CST> <Notice> <Security> <BEA-090169> <Loading trusted certificates from the jks keystore file /weblogic/Oracle/Middleware/Oracle_Home/wlserver/server/lib/DemoTrust.jks.> 
<2023-5-29 上午11时56分04,373秒 CST> <Notice> <Security> <BEA-090169> <Loading trusted certificates from the jks keystore file /usr/jdk1.8.0_371/jre/lib/security/cacerts.> 
Loading class `com.mysql.jdbc.Driver'. This is deprecated. The new driver class is `com.mysql.cj.jdbc.Driver'. The driver is automatically registered via the SPI and manual loading of the driver class is generally unnecessary.
<2023-5-29 上午11时56分07,182秒 CST> <Notice> <Log Management> <BEA-170027> <The server has successfully established a connection with the Domain level Diagnostic Service.> 
<2023-5-29 上午11时56分07,478秒 CST> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to ADMIN.> 
<2023-5-29 上午11时56分07,547秒 CST> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to RESUMING.> 
<2023-5-29 上午11时56分07,647秒 CST> <Notice> <Server> <BEA-002613> <Channel "Default" is now listening on 192.168.223.199:17010 for protocols iiop, t3, ldap, snmp, http.> 
<2023-5-29 上午11时56分07,649秒 CST> <Notice> <WebLogicServer> <BEA-000332> <Started the WebLogic Server Managed Server "appServer1" for domain "wls14cdomain" running in development mode.> 
<2023-5-29 上午11时56分07,650秒 CST> <Notice> <Server> <BEA-002613> <Channel "Default" is now listening on 192.168.223.199:17010 for protocols iiop, t3, ldap, snmp, http.> 
<2023-5-29 上午11时56分07,656秒 CST> <Notice> <WebLogicServer> <BEA-000360> <The server started in RUNNING mode.> 
<2023-5-29 上午11时56分07,678秒 CST> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to RUNNING.> 

在控制台修改驱动程序类的名称为:com.mysql.cj.jdbc.Driver,保存即可。

 在WebLogic安装目录下搜索,可以发现下面的驱动jar包

./Oracle/Middleware/Oracle_Home/oracle_common/modules/mysql-connector-java-commercial-8.0.14/mysql-connector-java-commercial-8.0.14.jar

下载到本地,使用压缩软件打开jar包,可以在com.mysql.cj.jdbc的包路径下,找到Driver.class类文件。

如果本地应用程序项目使用JDK1.8或者JDK11开发,且需要部署在WebLogic 14c服务器上,建议开发人员在本地项目中也采用上面的驱动Jar包和数据库驱动。

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 打赏
    打赏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

cnskylee

技术分享我是认真的,期待您打赏

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值