Skip to content

SavingsPlan workbook queries exceed ARG's documented 3-join limit #2227

Description

🛠️ Problem

The two queries in src/workbooks/optimization/SavingsPlan/SavingsPlan.workbook ("Savings plan Summary" and "Savings plan details") each contain 4 join operators, above Azure Resource Graph's documented limit of 3 joins per query:

  1. join on advisor suppressions (on stableId)
  2. join on advisor configurations, subscription level (on subscriptionId)
  3. join on advisor configurations, resource group level (on subscriptionId, resourceGroup)
  4. join kind=inner on resourcecontainers — only to fetch the subscription display name

ARG currently executes the queries without error (verified during PR #2225 testing), so this is a latent risk rather than an active failure: if the documented limit starts being enforced, both tiles break.

💡 Suggested fix

Drop join #4 and render the subscription name via a workbook column formatter / parameter instead — this is exactly why the equivalent Reservations queries (Reservations.workbook, commitment.workbook) stay at 3 joins. That also removes the join that had the innerunique data-loss bug fixed in PR #2225.

ℹ️ Additional context

Metadata

Metadata

Assignees

No one assigned

    Labels

    Skill: KQLKQL queries and Data Explorer integrationTool: WorkbooksAzure Monitor workbooksType: CleanupFixes to clean up any technical debt

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions