turbot/aws_well_architected

Query: wellarchitected_workload_pillar_risk_table

Usage

powerpipe query aws_well_architected.query.wellarchitected_workload_pillar_risk_table

SQL

select
p ->> 'PillarName' as "Pillar Name",
sum((p -> 'RiskCounts' ->> 'HIGH') :: int) as "High",
sum((p -> 'RiskCounts' ->> 'MEDIUM') :: int) as "Medium",
sum((p -> 'RiskCounts' ->> 'NONE') :: int) as "No Improvements",
sum((p -> 'RiskCounts' ->> 'NOT_APPLICABLE') :: int) as "Not Applicable"
from
aws_wellarchitected_lens_review as r,
jsonb_array_elements(r.pillar_review_summaries) as p
where
r.workload_id = $1
and r.lens_arn = any(string_to_array($2, ','))
group by
"Pillar Name"
order by
"Pillar Name"

Params

ArgsNameDefaultDescriptionVariable
$1workload_id
    $2lens_arn

      Dashboards

      The query is used in the dashboards: