How are Compute Units calculated in Application Gateway?
Dear Community,
I've been performing some experiments with Application Gateway today and was confused by an unexpected Compute Units calculation that leads to a very high consumptions.
Service configuration is simple:
- One listener
- One backend pool with one IP behind
- No WAF, No Rewrites
- Default SSL policy (AppGwSslPolicy20220101)
Here are the numbers:
- 266 (see screenshot) new connections per second
- About 30k active connections
- About 500 requests per second
- ... and > 40 Compute Units and Capacity Units as well
Based on the "Understanding pricing" documentation (https://learn.microsoft.com/en-us/azure/application-gateway/understanding-pricing), I've estimated the following:
- Based on connections, it should be 30k / 2500 = 12 CU
- Based on bandwidth (not on the screenshot, but it's less than 10Mbps) = 5 CU
- Based on Compute Unit description ("Each compute unit is capable of approximately 50 connections per second with RSA 2048-bit key TLS certificate.") it should be 500 / 50 = 10 CU
But Metrics show me 41.63, meaning that 1 Compute Unit can only handle 12 requests per second and 6 new connections per second?
Assuming I have 3k requests per second, Application Gateway would require near 250 CU and would cost me: ($0.246 + $0.008 x 250) x 730 = $1,639, though with 50 requests per second per CU it should be not more than ($0.246 + $0.008 x 60) x 730 = $529.
Is that an expected behavior? What's your experience with Application Gateway?
Thanks!