finops-toolkit icon indicating copy to clipboard operation
finops-toolkit copied to clipboard

[PBI]App Service Plan Rate Optimization showing 0 savings

Open josesarsa opened this issue 5 months ago • 11 comments

Effective Price for App Service Plan Premium 1v3 and 2v3 showing more effective cost than contracted one

Image

It cant be possible. Any thought?

josesarsa avatar Jul 10 '25 17:07 josesarsa

Is this resource covered by a reserved capacity? Effective cost can be higher if there is a commitment discount but the customer also has a negotiated discount that is higher than the RI discount. This query might help explaining the reason: Costs | extend EffectiveOverContracted = iff(ContractedCost < EffectiveCost, ContractedCost - EffectiveCost, decimal(0)) | extend ContractedOverList = iff(ListCost < ContractedCost, ListCost - ContractedCost, decimal(0)) | extend EffectiveOverList = iff(ListCost < EffectiveCost, ListCost - EffectiveCost, decimal(0)) | extend scenario = case( ListCost == 0 and CommitmentDiscountCategory == 'Usage' and ChargeCategory == 'Usage', 'Reservation usage missing list', ListCost == 0 and CommitmentDiscountCategory == 'Usage' and ChargeCategory == 'Purchase', 'Reservation purchase missing list', ListCost == 0 and CommitmentDiscountCategory == 'Spend' and ChargeCategory == 'Usage', 'Savings plan usage missing list', ListCost == 0 and CommitmentDiscountCategory == 'Spend' and ChargeCategory == 'Purchase', 'Savings plan purchase missing list', ListCost == 0 and ChargeCategory == 'Purchase', 'Other purchase missing list', isnotempty(CommitmentDiscountStatus) and ContractedOverList == 0 and EffectiveOverContracted < 0, 'Commitment cost over contracted', ListCost == 0 and BilledCost == 0 and EffectiveCost == 0 and ContractedCost > 0 and x_SourceChanges !contains 'MissingContractedCost', 'ContractedCost should be 0', ListCost == 0 and ContractedCost == 0 and BilledCost > 0 and EffectiveCost > 0 and x_PublisherCategory == 'Vendor' and ChargeCategory == 'Usage', 'Marketplace usage missing list/contracted', ContractedOverList < 0 and EffectiveOverContracted == 0 and x_SourceChanges !contains 'MissingListCost', 'ListCost too low', ContractedUnitPrice == x_EffectiveUnitPrice and EffectiveOverContracted < 0 and x_SourceChanges !contains 'MissingContractedCost', 'ContractedCost doesn''t match price', EffectiveOverContracted != 0 and abs(EffectiveOverContracted) < 0.00000001, 'Rounding error', ContractedOverList != 0 and abs(ContractedOverList) < 0.00000001, 'Rounding error', EffectiveOverList != 0 and abs(EffectiveOverList) < 0.00000001, 'Rounding error', ContractedCost < EffectiveCost or ListCost < ContractedCost or ListCost < EffectiveCost, '', EffectiveCost <= ContractedCost and ContractedCost <= ListCost, 'Good', '') | project-reorder ListCost, ContractedCost, BilledCost, EffectiveCost, EffectiveOverList, EffectiveOverContracted, ContractedOverList, x_SourceChanges, ListUnitPrice, ContractedUnitPrice, x_BilledUnitPrice, x_EffectiveUnitPrice, CommitmentDiscountStatus, PricingQuantity, PricingUnit, x_PricingBlockSize, x_PricingUnitDescription | summarize count(), EffectiveOverContracted = sum(EffectiveOverContracted), ContractedOverList = sum(ContractedOverList), EffectiveOverList = sum(EffectiveOverList), Type = arraystring(make_set(x_BillingAccountAgreement)) by scenario

arthurclares avatar Jul 11 '25 09:07 arthurclares

BTW, we have a PR open to document why you could see negative savings. It's waiting for review. Feel free to have a look and let's know what you think. Specially in this file: https://github.com/microsoft/finops-toolkit/blob/a253f7c29b18214389b5bcca9c71d3d15e820982/docs-mslearn/toolkit/hubs/savings-calculations.md

arthurclares avatar Jul 11 '25 09:07 arthurclares

I read that, it is self-explanatory

https://github.com/microsoft/finops-toolkit/blob/a253f7c29b18214389b5bcca9c71d3d15e820982/docs-mslearn/toolkit/hubs/savings-calculations.md

Regarding the troubleshooting part, I would really require some more explanation... Maybe a brief call next week. It is taking the information of two different contracts. I need to tune it a littble bit for the last months

josesarsa avatar Jul 11 '25 13:07 josesarsa

to pingpoint the issue I added | where BillingPeriodStart == startofmonth(now(), -3)

And I saw that in ListCost too low , I have -849,74 Contracterd over the list and EffectiveCostOverLis -26. The rest is almost zero

josesarsa avatar Jul 11 '25 13:07 josesarsa

I'd be interested in the outcome of this, I am seeing the same issue with Azure App Service Premium Pv3 Plan RIs.

Our Windows 3yr RIs are not showing any savings or ESR on the same report. We are still getting recommendations in the Azure portal at a higher discount rate than our MACC discount rate.

Indeed, our App Service Plans without any commitment coverage, are showing the List and Contracted amounts correctly, with our MACC discount as the ESR.

Edit: just to add, I'm using FinOps Hubs with Data Explorer

eltanko avatar Jul 11 '25 13:07 eltanko

Image

This is what I got

josesarsa avatar Jul 15 '25 11:07 josesarsa

Image This is what I got

I'm assuming you've got Pricesheet exports set up? We need those to get the correct list pricing and determine the correct ESR.

MSBrett avatar Aug 01 '25 19:08 MSBrett

I'd be interested in the outcome of this, I am seeing the same issue with Azure App Service Premium Pv3 Plan RIs.

Our Windows 3yr RIs are not showing any savings or ESR on the same report. We are still getting recommendations in the Azure portal at a higher discount rate than our MACC discount rate.

Indeed, our App Service Plans without any commitment coverage, are showing the List and Contracted amounts correctly, with our MACC discount as the ESR.

Edit: just to add, I'm using FinOps Hubs with Data Explorer

Advisor doesn't show pricing with your MACC discount included - known issue. The only place to see correct pricing in the portal in that scenario is when you go through the purchase wizard.

Do you have price sheet exports configured?
Without it we rely on the pricing in the costs dataset which which doesn't have correct list pricing for various types of commitments.

MSBrett avatar Aug 01 '25 19:08 MSBrett

Image This is what I got

I'm assuming you've got Pricesheet exports set up? We need those to get the correct list pricing and determine the correct ESR.

Yes, of course.

josesarsa avatar Aug 04 '25 09:08 josesarsa

I'd be interested in the outcome of this, I am seeing the same issue with Azure App Service Premium Pv3 Plan RIs.

Our Windows 3yr RIs are not showing any savings or ESR on the same report. We are still getting recommendations in the Azure portal at a higher discount rate than our MACC discount rate.

Indeed, our App Service Plans without any commitment coverage, are showing the List and Contracted amounts correctly, with our MACC discount as the ESR.

Edit: just to add, I'm using FinOps Hubs with Data Explorer

Advisor doesn't show pricing with your MACC discount included - known issue. The only place to see correct pricing in the portal in that scenario is when you go through the purchase wizard.

Do you have price sheet exports configured?
Without it we rely on the pricing in the costs dataset which which doesn't have correct list pricing for various types of commitments.

Yes, price list is exported

eltanko avatar Aug 04 '25 09:08 eltanko

After upgrading to 1.2. I am having 0 savings for all sort of reservations

josesarsa avatar Aug 26 '25 13:08 josesarsa