Skip to Main Content
Improve application performance with True Cache

About This Workshop

Youtube Video

About This Workshop
Why use True Cache?
True Cache can be used to scale a read-mostly application even without partitioning data. When primary database becomes the bottleneck , True Cache can be used to offload the primary and scale the workload. Also the data is always consistent and recent within a single query, this is important when there are joins across multiple rows.


This usage model of true cache through the JDBC requires minimal application change to use the functionality. Applications connect to only one service. Application uses setReadOnly(true) and setReadOnly(false) calls to mark some sections of code as "read only". If True Cache instances are configured, the JDBC driver will internally maintain, for each logical connection, 2 physical connections, one to a primary instance and one to an True Cache instance. The JDBC driver automatically sends SQL statements in "read-only" blocks to the True Cache instance.

What's in the workshop
This workshop is based on a compute instance (a demo application) connected to a Primary database configured with True Cache. The demo application is a Java program using the 23c JDBC driver. Its simulates a high number of transactions for the primary database and how off loading the read only queries to true cache helps in application performance.

It demonstrates:

How to set up True Cache.
Schema creation and initial data load to the primary database
The demo application shows the transactions running against the primary database and how switching to true cache helps in performance improvement .

Workshop Info

2 hours
  • Lab 1 Prepare Setup.
  • Lab 2 Environment Setup
  • Lab 3 Initialize Environment
  • Lab 4 Load Data into database
  • Lab 5 Use True Cache through jdbc
  • Lab 6 Clean up Stack and Instances
  • Familiarity with Oracle Database is desirable, but not required
  • Familiarity with Java and JDBC is desirable, but not required
  • Some understanding of cloud and database terms is helpful
  • Familiarity with Oracle Cloud Infrastructure (OCI) is helpful

Other Workshops you might like