turbot/aws_insights

Query: redshift_cluster_top10_cpu_past_week

Usage

powerpipe query aws_insights.query.redshift_cluster_top10_cpu_past_week

SQL

with top_n as (
select
cluster_identifier,
avg(average)
from
aws_redshift_cluster_metric_cpu_utilization_daily
where
timestamp >= CURRENT_DATE - INTERVAL '7 day'
group by
cluster_identifier
order by
avg desc
limit
10
)
select
timestamp,
cluster_identifier,
maximum
from
aws_redshift_cluster_metric_cpu_utilization_daily
where
timestamp >= CURRENT_DATE - INTERVAL '7 day'
and cluster_identifier in (
select
cluster_identifier
from
top_n
)
order by
timestamp;

Dashboards

The query is used in the dashboards: