Skip to content

Fix: include all Windows VMs in Azure Hybrid Benefit reports#1845

Merged
flanakin merged 2 commits intodevfrom
copilot/fix-hybrid-benefits-overview
Mar 2, 2026
Merged

Fix: include all Windows VMs in Azure Hybrid Benefit reports#1845
flanakin merged 2 commits intodevfrom
copilot/fix-hybrid-benefits-overview

Conversation

Copy link
Contributor

Copilot AI commented Oct 10, 2025

🛠️ Description

Replace hardcoded publisher checks (MicrosoftWindowsServer, microsoftsqlserver) with OS type checks (storageProfile.osDisk.osType) so that Windows VMs from all publishers (e.g., esri, safesoftwareinc) appear in AHB overviews.

Also removes the now-unnecessary custom image exclusion filter (extend OS=imageReference.id / where isnull(OS)) and consolidates the redundant OS type check in the summary query.

Fixes #1793

📋 Checklist

🔬 How did you test this change?

  • 🤏 Lint tests
  • 🤞 PS -WhatIf / az validate
  • 👍 Manually deployed + verified
  • 💪 Unit tests
  • 🙌 Integration tests

📦 Deploy to test?

  • Hubs + ADX (managed)
  • Hubs + Fabric (manual) — URI:
  • Hubs (manual)
  • Hubs (no data)
  • Workbooks
  • Alerts

🙋‍♀️ Do any of the following that apply?

  • 🚨 This is a breaking change.
  • 🤏 The change is less than 20 lines of code.

📑 Did you update docs/changelog.md?

  • ✅ Updated changelog (required for dev PRs)
  • ➡️ Will add log in a future PR (feature branch PRs only)
  • ❎ Log not needed (small/internal change)

📖 Did you update documentation?

  • ✅ Public docs in docs (required for dev)
  • ✅ Public docs in docs-mslearn (required for dev)
  • ✅ Internal dev docs in docs-wiki (required for dev)
  • ✅ Internal dev docs in src (required for dev)
  • ➡️ Will add docs in a future PR (feature branch PRs only)
  • ❎ Docs not needed (small/internal change)

@microsoft-github-policy-service microsoft-github-policy-service bot added the Skill: DevOps GitHub setup and automation label Oct 10, 2025
@microsoft-github-policy-service microsoft-github-policy-service bot added Skill: Documentation Documentation updates Tool: FinOps guide Implementing FinOps guide Needs: Review 👀 PR that is ready to be reviewed labels Oct 10, 2025
Copilot AI changed the title [WIP] Fix missing Windows VMs from Hybrid Benefits overviews Fix: Include all Windows VMs in Azure Hybrid Benefit workbooks regardless of publisher Oct 10, 2025
Copilot AI requested a review from MSBrett October 10, 2025 20:41
@flanakin flanakin added this to the v14 milestone Jan 6, 2026
@flanakin flanakin modified the milestones: v14, v15 Feb 23, 2026
Replace hardcoded publisher checks (MicrosoftWindowsServer, microsoftsqlserver)
with OS type checks (storageProfile.osDisk.osType) so that Windows VMs from
all publishers (e.g., esri, safesoftwareinc) appear in AHB overviews.

Also removes the now-unnecessary custom image exclusion filter
(extend OS=imageReference.id / where isnull(OS)) and consolidates
the redundant OS type check in the summary query.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@flanakin flanakin force-pushed the copilot/fix-hybrid-benefits-overview branch from a1532ff to 9d21ca5 Compare March 2, 2026 11:51
@flanakin flanakin changed the title Fix: Include all Windows VMs in Azure Hybrid Benefit workbooks regardless of publisher Fix: include all Windows VMs in Azure Hybrid Benefit reports Mar 2, 2026
@microsoft-github-policy-service microsoft-github-policy-service bot added the Micro PR 🔬 Very small PR that should be especially easy for newcomers label Mar 2, 2026
@flanakin flanakin marked this pull request as ready for review March 2, 2026 12:04
Copilot AI review requested due to automatic review settings March 2, 2026 12:04
@flanakin flanakin merged commit 20b3822 into dev Mar 2, 2026
5 checks passed
@flanakin flanakin deleted the copilot/fix-hybrid-benefits-overview branch March 2, 2026 12:04
@flanakin flanakin modified the milestones: v15, v14 Mar 2, 2026
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR fixes a bug in the Azure Hybrid Benefit (AHB) workbook reports where Windows VMs from non-Microsoft publishers (e.g., esri, safesoftwareinc) were excluded from AHB overviews. The fix replaces hardcoded publisher checks with OS type checks (storageProfile.osDisk.osType), making the queries publisher-agnostic and also removes now-unnecessary custom image exclusion filters.

Changes:

  • KQL queries in both AHB workbooks updated to filter on osDisk.osType == 'Windows' instead of image publisher names
  • Custom image exclusion filter (extend OS=imageReference.id / where isnull(OS)) removed from AHB/AHB.workbook
  • Changelog updated with fix entry under v14

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.

File Description
src/workbooks/optimization/Compute/AHB.workbook Updated AHB Disabled and AHB Enabled queries to use osDisk.osType checks instead of publisher checks
src/workbooks/optimization/AHB/AHB.workbook Updated four queries (AHB Disabled, AHB Enabled, two summary charts) to use osDisk.osType checks and removed custom image exclusion filters
docs-mslearn/toolkit/changelog.md Added changelog entry for the fix under FinOps workbooks v14, updated ms.date to 03/02/2026

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Micro PR 🔬 Very small PR that should be especially easy for newcomers Needs: Review 👀 PR that is ready to be reviewed Skill: DevOps GitHub setup and automation Skill: Documentation Documentation updates Tool: FinOps guide Implementing FinOps guide

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Windows VMs based on other images are not present in the Hybrid Benefits overviews

6 participants