The FlexDeploy distribution for Tomcat includes the binaries for Tomcat, the FlexDeploy WAR, and the base configurations, leaving only a few simple steps to complete the install. The distribution contains the following components.
...
Tip |
---|
title | Example JDBC URL (CONNECT_STRING) |
---|
|
- Oracle
- The JDBC short format of host:sid:port should not be used. URL must be in the format listed below as we are recommending user of UCP based connection pooling.
- Example - jdbc:oracle:thin:@(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=tcp)(HOST=**HOSTNAME**)(PORT=**PORT**)))(CONNECT_DATA=(SERVICE_NAME=**SERVICE_NAME**)))
- If RAC is used for the database, multiple nodes can be listed in the address list of the URL or it can point to the scan listener for the cluster.
Sample - See below sample URL for a RAC implementation that has a primary and secondary scan listener connecting to to a service name GOLD-CLOUD. This includes connection timeout, retry, and retry delay settings.
- Example - jdbc:oracle:thin:@(DESCRIPTION = CONNECT_TIMEOUT=120) (RETRY_COUNT=20) (RETRY_DELAY=3) (TRANSPORT_CONNECT_TIMEOUT=3) (ADDRESS_LIST =(LOAD_BALANCE=on) (ADDRESS = (PROTOCOL = TCP) (HOST=primary-scan) (PORT=1521))) (ADDRESS_LIST =(LOAD_BALANCE=on) (ADDRESS = (PROTOCOL = TCP) (HOST=secondary-scan) (PORT=1521))) (CONNECT_DATA=(SERVICE_NAME = gold-cloud)))
- For more information about using UCP please check here.
- PostgreSQL
- MySQL
|
...
- Download the latest Oracle JDBC driver from https://www.oracle.com/database/technologies/appdev/jdbc-ucp-19c-downloads.html. For example, ojdbc8-full.tar.gz.
- Remove ojdbc jar files like ojdbc*.jar or ojdbc*dms.jar from <FlexDeploy Home>/apache-tomcat-flexdeploy/lib.
- Copy ojdbc8.jar, ons.jar anducp.jar from download archive to <FlexDeploy Home>/apache-tomcat-flexdeploy/lib.
...
If you leave multiple Oracle JDBC drivers in the lib folder, you could encounter the following exception on startup. Remove the old versions of the driver.
...
- UCP is now required for Oracle Database connections. See Implementing UCP connections with Tomcat and Oracle for more info.
Step 9. (Linux only) - set the shell scripts executable with this command.
...
Note |
---|
title | Note for Oracle XE Database |
---|
|
After starting your server, check the <FlexDeploy Home>/apache-tomcat-flexdeploy/logs/flexdeploy.0.log file for the following error message: - ORA-12519, TNS:no appropriate service handler found
If present, increase the number of processes for the database - Using SQLPlus update processes setting.
- alter system set processes=200 scope=spfile;
- Stop Tomcat
- Restart the XE Database
- Start Tomcat
|
...