True Cache

Oracle True Cache is an in-memory, consistent, and automatically managed SQL cache for Oracle Database. True Cache improves application response time while reducing the load on the database. Automatic cache management and consistency simplify application development, reducing development effort and cost.

True Cache on Oracle Database 23ai — Overview (1:47)
Aankondiging: generatieve ontwikkeling voor bedrijven (GenDev)

Bekijk de herhaling van EVP Juan Loaiza's keynote op Oracle CloudWorld en kom meer ter weten over deze baanbrekende, AI-centrische AppDev-infrastructuur.

Why choose Oracle True Cache?

Real-time, consistent data

Oracle True Cache automatically keeps the most frequently accessed data in the cache, which keeps the cache consistent with the database.

Simplified cache management

Cache contents are automatically loaded when accessed and refreshed when the data changes. Oracle True Cache supports all Oracle Database APIs and data types, including relational, JSON, text, spatial, graph, and vector data types. Data in True Cache can be accessed in a row or columnar format using the same Oracle Database APIs.

Improve scalability

Oracle True Cache improves scalability and application response time by offloading queries and reducing the number of requests to the database.

Cost-effective generative AI

Retrieval augmented generation (RAG) typically involves back-end calls to large language models (LLMs). Caching these outcomes lowers the cost associated with LLM usage.

Use high performance flash for extended cache

True Cache allows data to be stored on disk if it cannot fit into the memory of the True Cache compute instance. This allows the cache to hold more data than what could fit in the memory of the compute instance, thereby expanding the total cache size.

High availability and multi-threading

True Cache redefines cache management with extreme performance, leveraging multi-threading and utilizing all cores/vCPUs on a host. It ensures native high availability, guaranteeing data resilience and continuous availability during node failures or network disruptions.

How True Cache works

True Cache is a fully functional, read-only replica of the primary database that is mostly diskless.

Modern applications often require a high number of connections and fast, low-latency access to the data. A popular approach is to place caches in front of the database because applications typically perform many more reads than updates, and they can read from the cache without affecting database performance. For example, an airline reservation system reads data frequently as people shop for flights. It's okay if the data isn't the most current compared to what's in the database because the application only needs to access the most current data when someone reserves a flight.

Unlike conventional caches, True Cache automatically keeps the most frequently accessed data in the cache, and it keeps the cache consistent with the primary database, other objects in the same cache, and other caches. It caches all Oracle Database objects and data types, including JSON.

Because True Cache implements Oracle Database security policies, you can control access to the cache. This enables you to cache sensitive data, such as private personal information, that you might not ordinarily cache.

An application decides whether to query data from True Cache or the primary database. For example, the application can maintain two connections: a read-only connection to True Cache and a read/write connection to the database. Alternatively, a Java application can use one connection and dynamically switch between True Cache and the database by setting the read-only attribute.

With True Cache, data is always consistent within a single query. This is even more important when there are joins across multiple rows; doing this at the application level can lead to incorrect results.

True Cache diagram

How True Cache works diagram description

  1. 1. An application directs queries to True Cache either manually or semiautomatically via the Oracle JDBC driver.
  2. 2. A True Cache instance satisfies queries by using data that it caches for the database application services that it handles.
  3. 3. When a cache miss occurs, a True Cache instance fetches blocks from the primary database instance.
  4. 4. When a True Cache instance is first initialized, SQL queries are fired to warm up the cache, resulting in the fetching of surrounding blocks in large chunks.
  5. After a block is cached, it's automatically updated through redo apply from a primary database, usually with a subsecond lag.This is similar to how a real-time redo apply happens in an Oracle Data Guard configuration. The primary database redo blocks are continuously sent to the True Cache standby redo log files by the Log Writer (LGWR) process on the primary database instance in ASYNC mode.
  6. 5. A query to True Cache returns only committed data that's as recent as the redo apply lag.
  7. 6. Each query to a True Cache instance always returns consistent data.
  8. 7. True Cache improves scalability by offloading queries and reduces the number of requests to primary database.

True Cache use cases

  • Generative AI

    Streamline AI development process through retrieval augmented generation (RAG) and LLM caching.

  • Ecommerce applications

    Customers retrieve data for online product catalogs by accessing Oracle True Cache instead of the back-end database. This process improves response times and elevates the customer experience during peak sales periods, such as Black Friday, Cyber Monday, and prime-time television events.

  • Data sovereignty

    Oracle True Cache offloads reads to instances that are deployed closer to the end user or sovereign regions, speeding up analytics response times and maintaining data sovereignty.

  • Online gaming

    Oracle True Cache reduces latency and improves the immersive gaming experience by storing real-time player data, supporting features such as leader boards and user rankings.

  • User authentication

    Oracle True Cache handles millions of daily updates to user profiles, validating the application user in real time. It also supports multiple data models to natively store different types of elements, reducing complexity and costs.

  • Real-time analytics

    Oracle True Cache can be used to cache data and offload database I/O to reduce the operational burden, lower costs, and improve the performance of both the database and the application.

  • Edge computing

    Oracle True Cache can be deployed in regions closer to users or devices, reducing the time needed to collect, store, and retrieve data from databases.

September 19, 2023

Elevating Performance: Introducing Oracle True Cache for Global Availability

Pankaj Chandiramani, Sr Director of Product Management

Introducing Oracle True Cache : In-memory, consistent, and automatically managed SQL and key-value (object) cache.

Featured Database blogs

View all

Get started with Oracle True Cache


Try Oracle Cloud Free Tier

Build, test, and deploy applications on Oracle Cloud Infrastructure Platform.


Documentation

Oracle True Cache user’s guide.


Contact us

Interested in learning more? Contact one of our industry-leading experts.