Note
For V4.6.0, this parameter is available starting with V4.6.0.
Description
ttl_duty_time specifies the time when the TTL task is periodically triggered in the background.
Privilege requirements
Query the parameter
systenant and all user tenants can use theSHOW PARAMETERSstatement or theGV$OB_PARAMETERSview to query this parameter.Modify the parameter
systenant and user tenants can modify this parameter.
Attributes
| Attribute | Description |
|---|---|
| Type | Moment |
| Default value | 01:00 |
| Value range | [00:00, 24:00), and the time zone is specified by the system variable time_zone. |
| Modifiable | Yes. You can use the ALTER SYSTEM SET statement to modify the parameter. |
| Effective upon OBServer node restart | No. The setting takes effect immediately. |
Considerations
This parameter takes effect only when the tenant-level parameter enable_ttl is set to
True. After the specified start time is reached, the system starts to traverse all tables with the TTL attribute in the tenant and executes the TTL task for these tables.The time specified by
ttl_duty_timeis in the same time zone as the tenant. We recommend that you set the time to a low-traffic period of the tenant and before the daily major compaction is initiated.
Examples
Set the time when the TTL task is periodically triggered in the background for the user tenant to
02:00in the system tenant.obclient(root@sys)[(none)]> ALTER SYSTEM SET ttl_duty_time = '02:00' TENANT = tenant_name;Set the time when the TTL task is periodically triggered in the background for the user tenant to
02:00.obclient> ALTER SYSTEM SET ttl_duty_time = '02:00';
References
Enable the TTL feature: enable_ttl
