Applications that use JDBC Thin connections include the software
necessary to make an Oracle Net Services connection. It is not necessary to download
and install Oracle Client software.
Some applications use the JDK installed on your computer while others use a JDK that
is embedded in the application installation. If your application
uses the JDK installed on your computer and that JDK is version 8,
8u161 or later, no additional preparation is required. If your
computer does not have JDK version 8, 8u161 or later, already
installed then install the latest JDK first. You can download the
latest JDK from https://www.java.com/.
If your application is using a JDK version 8, prior to 8u161, then the JCE Policy Files must be updated within your application.
See Connect with JDBC Thin Driver for the steps required to use JDBC Thin
connections to connect to an Oracle Database server.
Set JVM Networking Properties Autonomous Database uses DNS names that map to multiple IP addresses (multiple load balancers) for better availability and performance. Depending on your application, you may want to configure certain JVM networking properties.
Autonomous Database uses DNS
names that map to multiple IP addresses (multiple load balancers) for better availability
and performance. Depending on your application, you may want to configure certain JVM
networking properties.
For the Java Virtual Machine (JVM) address cache, any address resolution
attempt caches the result whether it was successful or not, so that subsequent identical
requests do not have to access the naming service. The address cache properties allow
you to tune how the cache operates. In particular, the
networkaddress.cache.ttl value specifies the number of seconds a
successful name lookup is kept in the cache. A value of -1, the default value, indicates
a “cache forever” policy, while a value of 0 (zero) means no
caching.
If your Java Virtual Machine (JVM) is configured to cache DNS address
lookups, your application may be using only one IP address to connect to your Autonomous Database, resulting in lower
throughput. To prevent this you can change your JVM's
networkaddress.cache.ttl value to 0, so that every
connection request does a new DNS lookup. This ensures that different threads in your
application are distributed over multiple load balancers.
To change the networkaddress.cache.ttl value for all
applications, or in your application, do one of the following:
Configure the security policy to set the value for all applications:
Set networkaddress.cache.ttl=0 in the file
$JAVA_HOME/jre/lib/security/java.security
Set the following property in your application
code: