Oracle TimesTen Application-Tier Database Cache Overview

Oracle TimesTen In-Memory Database (TimesTen) is a full-featured, memory-optimized, relational database that provides very fast response time and high throughput to mission critical applications. TimesTen can be deployed as TimesTen Scaleout and TimesTen Classic. TimesTen Classic includes Oracle TimesTen Application-Tier Database Cache (TimesTen Cache)1 option. This page contains overview of the Timesten Cache option. TimesTen Cache is an Oracle Database product option ideal for caching a performance-critical subset of an Oracle database in the application tier for improved response time. Applications perform read/write operations on the cache tables using SQL and PL/SQL with automatic persistence, transactional consistency, and data synchronization with the Oracle database. (Product Data Sheet)

For many enterprise applications, the majority of data in the corporate databases is historical and infrequently accessed. However, buried within this data are pockets of information that must be instantly accessible. For example, current active customers/users, open orders, recent transactions, product catalogs, etc.; caching these data in memory can yield significant improvement for application response time.

Oracle TimesTen In-Memory Database

TimesTen Cache is based on the same technology as TimesTen Classic with the addition of the caching functionality and is deployed in the application tier for multi-user and multi-threaded applications. Applications connect to the cache database and access the cached tables using standard SQL via JDBC, ODBC, ADO.NET, Oracle Call Interface (OCI), Pro*C/C++, and Oracle PL/SQL programming interfaces. Cached tables operate like regular relational tables inside the TimesTen database and are persistent and recoverable.

Applications using TimesTen Cache may choose to configure a combination of caching options:

  • Read-only caches - transactions are performed in the Oracle Database and the changes are refreshed to the TimesTen cache database.
  • Read-write (or write-through) caches – transactions are performed in the TimesTen cache database and then propagated to the Oracle Database.
  • On-demand and preloaded cached - data may be loaded on-demand or preloaded, and may be shared across the cache grid members, or reside only in a specific cache node.

Data synchronization with the Oracle Database is performed automatically.

  • Asynchronous write-through cache leverages the speed of TimesTen by first committing the transactions locally in the cache database, and asynchronously sending the updates to the Oracle Database. Asynchronous write-through cache groups provide faster application response time and higher transaction throughput.
  • Synchronous write-through cache will ensure that if the Oracle Database cannot accept the update(s), the transaction is rolled back from the cache database; with synchronous write-through, the application must wait for the commits to complete in both the Oracle Database and the TimesTen database.
  • For read-only caches, incremental updates in the Oracle Database are asynchronously refreshed to the in-memory cache tables in the application-tier at user-specified intervals.

TimesTen Cache is designed to continue running even after the Oracle Database server or network connection has been lost. Committed transactions to the cache database are tracked and persisted; and once the connection to the Oracle Database is restored, the transactions are propagated to the Oracle Database. Similarly, committed transactions on the source tables in the Oracle Database are tracked and refreshed to the TimesTen database once connection between the databases is re-established.

Similar to the stand-alone TimesTen databases, TimesTen Cache offers built-in mechanisms for transactional replication to provide high availability for the cache databases. Most enterprise applications cannot afford application down time, hence majority of the deployments add TimesTen Cache replication for high availability and load balancing.