ttAgingLRUConfig
The ttAgingLRUConfig
procedure sets the Least Recently Used (LRU) aging attributes in terms of the percentage of MB that rows occupy. You can use it on all regular tables defined with an LRU aging policy.
LRU aging enables you to maintain the amount of memory used in a TimesTen database within a specified threshold by deleting the least recently used data. Data is removed if the database space in-use exceeds the specified threshold values.
For cache groups, LRU aging is defined at the root table for the entire cache instance. LRU aging can be defined for all cache group types except for explicitly loaded autorefresh cache groups. LRU aging is defined by default on dynamic cache groups. For explicitly loaded cache groups, use time-based aging.
For cache tables, the aging policy is defined on the root table but applies to all tables in the cache group. The aging policy is defined on tables when they are created or altered, using the CREATE TABLE
or ALTER TABLE
SQL statements.
Required Privilege
This procedure requires no privilege to query the current values. It requires the ADMIN
privilege to change the current values.
Usage in TimesTen Scaleout and TimesTen Classic
This procedure is supported in TimesTen Classic but not supported in TimesTen Scaleout.Related Views
This procedure has no related views.
Syntax
ttAgingLRUConfig([LowUsageThreshHold], [HighUsageThreshHold], [AgingCycle])
Parameters
ttAgingLRUConfig
has these optional parameters:
Parameter | Type | Description |
---|---|---|
|
|
Sets, displays or resets the low end of percentage of database |
|
|
Sets, displays or resets the high end of percentage of database |
|
|
Sets, displays or resets the number of minutes between aging cycles, specified in minutes. Default is 1 minute. If you use this procedure to change the aging cycle, the cycle is reset based on the time that this procedure is called. For example, if you call this procedure at 12:00 p.m. and specify a cycle of 15 minutes, aging occurs at 12:15, 12:30, 12:45, and so on. If the cycle is set to a value of |
Result Set
ttAgingLRUConfig
returns these results:
Column | Type | Description |
---|---|---|
|
|
The current setting for the low end of percentage of database |
|
|
The current setting for the high end of percentage of database |
|
|
The current setting for the number of minutes between aging cycles, specified in minutes. |
Examples
To set the aging threshold to a low of 75 percent and a high of 95 percent and the aging cycle to 5 minutes, use:
CALL ttAgingLRUConfig (.75, .90, 5); <.7500000, .9000000, 5>
To display the current LRU aging policy for all tables that defined with an LRU aging policy, call ttAgingLRUConfig
without any parameters:
CALL ttAgingLRUConfig();
If the tables are defined with the default thresholds and aging cycle, the procedure returns:
<.8000000, .9000000, 1> 1 row found.
To change the low usage threshold to 60 percent, the aging cycle to 5 minutes and to retain the previous high usage threshold, use:
CALL ttAgingLRUConfig (60,,5); < .6000000, .9000000, 5 > 1 row found.
Note:
The values of this procedure are persistent, even across system failures.
If no parameters are supplied, this procedure only returns the current LRU aging attribute settings.
See Also
- ttAgingTableLRUConfig
- ttAgingScheduleNow
- Usage-Based Aging in the Oracle TimesTen In-Memory Database Operations Guide