# mariyaali/fabric-dw-query-capacity-correlation architecture

> Architecture diagram of the GitHub repository mariyaali/fabric-dw-query-capacity-correlation, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-11). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/mariyaali/fabric-dw-query-capacity-correlation
- Repository: https://github.com/mariyaali/fabric-dw-query-capacity-correlation

## Overview

This repository provides a customer-owned Power BI report for correlating Fabric Capacity Metrics with Warehouse Query Insights. The principal workflow is to configure the template for a capacity and accessible Warehouses, refresh its semantic model, then investigate utilization spikes alongside query details. The README documents those product relationships; source excerpts were unavailable, so implementation-level calls and finer-grained model internals are not asserted.

Main entry points: [`Configure-CustomerTemplate.ps1`](https://github.com/mariyaali/fabric-dw-query-capacity-correlation/blob/main/Configure-CustomerTemplate.ps1) (Template configuration), [`Template/Query Capacity Correlation.SemanticModel/definition`](https://github.com/mariyaali/fabric-dw-query-capacity-correlation/tree/main/Template/Query%20Capacity%20Correlation.SemanticModel/definition) (Correlation semantic model), [`Template/Query Capacity Correlation.Report/definition`](https://github.com/mariyaali/fabric-dw-query-capacity-correlation/tree/main/Template/Query%20Capacity%20Correlation.Report/definition) (Power BI report), [`Template`](https://github.com/mariyaali/fabric-dw-query-capacity-correlation/tree/main/Template) (Configured report package)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_setup["Customer setup"]
  node_configuration["Template configuration"]
  node_configuredreport["Configured report package"]
end

subgraph group_data["Data and modeling"]
  node_capacitymetrics[("Capacity Metrics model")]
  node_warehouses[("Fabric Warehouses")]
  node_queryinsights["Query Insights queries"]
  node_semanticmodel[("Correlation semantic model<br/>[definition]")]
end

subgraph group_analysis["Capacity analysis"]
  node_report["Power BI report<br/>[definition]"]
  node_investigation(("Spike investigation"))
end

node_customer(("Customer analyst"))
node_azurecli["Azure CLI sign-in"]

node_azurecli -->|"signs in"| node_configuration
node_customer -->|"runs configuration"| node_configuration
node_configuration -->|"discovers warehouses"| node_warehouses
node_configuration -->|"creates package"| node_configuredreport
node_configuredreport -->|"configures connection"| node_semanticmodel
node_capacitymetrics -->|"provides metrics"| node_semanticmodel
node_warehouses -->|"exposes query history"| node_queryinsights
node_queryinsights -.->|"supplies query data"| node_semanticmodel
node_semanticmodel -->|"feeds visuals"| node_report
node_customer -->|"selects time range"| node_report
node_report -->|"shows query correlations"| node_investigation
node_customer -->|"reviews query details"| node_investigation

click node_configuration "https://github.com/mariyaali/fabric-dw-query-capacity-correlation/blob/main/Configure-CustomerTemplate.ps1"
click node_configuredreport "https://github.com/mariyaali/fabric-dw-query-capacity-correlation/tree/main/Template"
click node_queryinsights "https://github.com/mariyaali/fabric-dw-query-capacity-correlation/blob/main/query-executions.template.sql"
click node_semanticmodel "https://github.com/mariyaali/fabric-dw-query-capacity-correlation/tree/main/Template/Query%20Capacity%20Correlation.SemanticModel/definition"
click node_report "https://github.com/mariyaali/fabric-dw-query-capacity-correlation/tree/main/Template/Query%20Capacity%20Correlation.Report/definition"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_configuration,node_configuredreport toneBlue
class node_capacitymetrics,node_warehouses,node_queryinsights,node_semanticmodel toneAmber
class node_report,node_investigation toneMint
class node_customer,node_azurecli toneIndigo
```

## Components

### Customer setup

- [Template configuration](https://github.com/mariyaali/fabric-dw-query-capacity-correlation/blob/main/Configure-CustomerTemplate.ps1): `Configure-CustomerTemplate.ps1`
- [Configured report package](https://github.com/mariyaali/fabric-dw-query-capacity-correlation/tree/main/Template): `Template`

### Data and modeling

- **Capacity Metrics model**
- **Fabric Warehouses**
- [Query Insights queries](https://github.com/mariyaali/fabric-dw-query-capacity-correlation/blob/main/query-executions.template.sql): `query-executions.template.sql`
- [Correlation semantic model](https://github.com/mariyaali/fabric-dw-query-capacity-correlation/tree/main/Template/Query%20Capacity%20Correlation.SemanticModel/definition): `Template/Query Capacity Correlation.SemanticModel/definition`

### Capacity analysis

- [Power BI report](https://github.com/mariyaali/fabric-dw-query-capacity-correlation/tree/main/Template/Query%20Capacity%20Correlation.Report/definition): `Template/Query Capacity Correlation.Report/definition`
- **Spike investigation**

### Other components

- **Customer analyst**
- **Azure CLI sign-in**

## Connections

- Azure CLI sign-in → Template configuration: signs in (evidence: `README.md`)
- Customer analyst → Template configuration: runs configuration (evidence: `README.md`)
- Template configuration → Fabric Warehouses: discovers warehouses (evidence: `README.md`)
- Template configuration → Configured report package: creates package (evidence: `README.md`)
- Configured report package → Correlation semantic model: configures connection (evidence: `README.md`)
- Capacity Metrics model → Correlation semantic model: provides metrics (evidence: `README.md`)
- Fabric Warehouses → Query Insights queries: exposes query history (evidence: `README.md`)
- Query Insights queries → Correlation semantic model: supplies query data
- Correlation semantic model → Power BI report: feeds visuals (evidence: `README.md`)
- Customer analyst → Power BI report: selects time range (evidence: `README.md`)
- Power BI report → Spike investigation: shows query correlations (evidence: `README.md`)
- Customer analyst → Spike investigation: reviews query details (evidence: `README.md`)
