X

Proactive insights, news and tips from Oracle WebLogic Server Support. Learn Oracle from Oracle.

Oracle 18.3 Database Support with WebLogic Server

Stephen Felts
Manager

The Oracle 18.3 database is available and works with WebLogic Server (WLS) .

Using Older Drivers with the 18.3 Database Server

The simplest integration of WebLogic Server with an Oracle 18.3 database is to use the Oracle driver jar files included in your WebLogic Server installation. There are no known problems or upgrade issues when using 11.2.x or 12.x drivers shiped with WLS when interoperating with an Oracle 18.3 database.  See the Oracle JDBC FAQ for more information on driver support and features of Oracle 18.3 database.

Using the Oracle 18.3 Drivers with the 18.3 Database Server

To use many of the new 18.3 database features, it is necessary to use the 18.3 database driver jar files.

Note that Oracle 18.3 database driver jar files are compiled for JDK 8. The earliest release of WLS that supports JDK 8 is WLS 12.1.3. The Oracle 18.3 database driver jar files cannot work with earlier versions of WLS.  In earlier versions of WLS you can use the drivers that come with the WLS installation to connect to the 18.3 DB, as explained above.  At this time, this article does not apply to Fusion MiddleWare (FMW) deployments of WLS..

Required Oracle 18.3 Driver Files

At this time, no release of WLS ships with the 18.3 Oracle database jar files.

This section lists the files required to use an Oracle 18.3 driver with these releases of WebLogic Server .

Note: These jar files must be added to the CLASSPATH used for running WebLogic Server at the head of the CLASSPATH. They must come before all of the 11.2.x or 12.x Oracle database client jar files.

Select one of the following ojdbc files (note that these have "8" in the name instead of "7" from the earlier release)   The _g jar files are using for debugging and required if you want to enable driver level logging.  If you are using FMW, you must use the "dms" version of the jar file.  WLS uses the non-"dms" version of the jar by default.

  • ojdbc8-full/ojdbc8.jar

  • ojdbc8-diag/ojdbc8_g.jar

  • ojdbc8-diag/ojdbc8dms.jar

  • ojdbc8-diag/ojdbc8dms_g.jar

    The following table lists additional required driver files:

     

File

Description

ojdbc8-full/simplefan.jar

Fast Application
Notification

ojdbc8-full/ucp.jar

Universal Connection Pool

ojdbc8-full/ons.jar

Oracle Network Server
client

ojdbc8-full/orai18n.jar

Internationalization
support

ojdbc8-full/oraclepki.jar

Oracle Wallet support

ojdbc8-full/osdt_cert.jar

Oracle Wallet support

ojdbc8-full/osdt_core.jar

Oracle Wallet support

ojdbc8-full/xdb6.jar

SQLXML support

 

Download Oracle 18.3 Database Files

You can download the required jar files from https://www.oracle.com/technetwork/database/application-development/jdbc/downloads/jdbc-ucp-183-5013470.html.  The ojdbc8-full jar files are contained in ojdbc8-full.tar.gz and the ojdbc8-diag files are contained in ojdbc8-diag.tar.gz.  It is recommended to unpackage both of these files under a single directory, maintaining the directory structure (e.g., if the directory is /share, you would end up with /share/ojdbc8-full and /share/ojdbc8-diag directories).

Note: In earlier documents, instructions included installation of aqjms.jar to run with AQJMS and xmlparserv2_sans_jaxp_services.jar, orai18n-collation.jar, and orai18n-mapping.jar for XML processing,  These jar files are not available in the Oracle Database 18c (18.3) JDBC Driver & UCP Downloads.  If you need one of these jar files, you will need to install the Oracle Database client, the Administrator package client installation, or a full database installation to get the jar files and add them to the CLASSPATH..

Update the WebLogic Server CLASSPATH or PRE_CLASSPATH

To use an Oracle 18.3 JDBC driver, you must update the CLASSPATH in your WebLogic Server environment. Prepend the required files specified in Required Oracle 18.3 Driver Files listed above to the CLASSPATH (before the 12.x Driver jar files).  If you are using startWebLogic.sh, you also need to set the PRE_CLASSPATH. The following code sample outlines a simple shell script that updates the CLASSPATH of your WebLogic environment. Make sure ORACLE183 is set appropriately to the directory where the files were unpackaged (e.g., /share in the example above)..

#!/bin/sh
# source this file in to add the new 18.3 jar files at the beginning of the CLASSPATH
case "`uname`" in
*CYGWIN*)
SEP=";"
;;
Windows_NT)
SEP=";"
;;
*)
SEP=":"
;;
esac

dir=${ORACLE183:?}
# We need one of the following

#ojdbc8-full/ojdbc8.jar
#ojdbc8-diag/lib/ojdbc8_g.jar
#
ojdbc8-diag/lib/ojdbc8dms.jar
#
ojdbc8-diag/lib/ojdbc8dms_g.jar

if [ "$1" = "" ]
then
ojdbc=ojdbc8.jar
else
ojdbc="$1"
fi

case "$ojdbc" in
ojdbc8.jar)
ojdbc=
ojdbc8-full/$ojdbc
;;
ojdbc8_g.jar|ojdbc8dms.jar|ojdbc8dms_g.jar)
ojdbc=
ojdbc8-diag/$ojdbc
;;
*)
echo "Invalid argument - must be ojdbc8.jar|ojdbc8_g.jar|ojdbc8dms.jar|ojdbc8dms_g.jar"
exit 1
;;
esac

CLASSPATH="${dir}/${ojdbc}${SEP}$CLASSPATH"
CLASSPATH="${dir}/
ojdbc8-full/simplefan.jar${SEP}$CLASSPATH"
CLASSPATH="${dir}/
ojdbc8-full/ucp.jar${SEP}$CLASSPATH"
CLASSPATH="${dir}/
ojdbc8-full/ons.jar${SEP}$CLASSPATH"
CLASSPATH="${dir}/
ojdbc8-full/orai18n.jar${SEP}$CLASSPATH"
CLASSPATH="${dir}/
ojdbc8-full/oraclepki.jar ${SEP}$CLASSPATH"
CLASSPATH="${dir}/
ojdbc8-full/osdt_cert.jar ${SEP}$CLASSPATH"
CLASSPATH="${dir}/
ojdbc8-full/osdt_core.jar${SEP}$CLASSPATH"
CLASSPATH="${dir}/
ojdbc8-full/xdb6.jar${SEP}$CLASSPATH"

For example, save this script in your environment with the name setdb183_jars.sh. Then run script with ojdbc8.jar:

. ./setdb183_jars.sh ojdbc8.jar

export PRE_CLASSPATH="$CLASSPATH" 

Be the first to comment

Comments ( 0 )
Please enter your name.Please provide a valid email address.Please enter a comment.CAPTCHA challenge response provided was incorrect. Please try again.Captcha