Loading controls...
Control: NoSQL tables with stale data should be reviewed
Description
If the data has not changed recently and has become stale, the table should be reviewed.
Usage
Run the control in your terminal:
steampipe check oci_thrifty.control.nosql_table_stale_data
Snapshot and share results via Steampipe Cloud:
steampipe loginsteampipe check --share oci_thrifty.control.nosql_table_stale_data
Plugins & Tables
Params
Args | Name | Default | Description | Variable |
---|---|---|---|---|
$1 | nosql_table_stale_data_max_days |
| The maximum number of days table data can be unchanged before it is considered stale. |
SQL
select a.id as resource, case when date_part('day', now() - (time_updated :: timestamptz)) > $1 then 'alarm' else 'ok' end as status, a.title || ' was changed ' || date_part('day', now() - (time_updated :: timestamptz)) || ' day(s) ago.' as reason, coalesce(c.name, 'root') as compartment, a.regionfrom oci_nosql_table as a left join oci_identity_compartment as c on c.id = a.compartment_id;