You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It is not actually a bug but a better and simpler computation exist. Currently, time to drain metrics in SQS is calculated as below [1] , which is indirect. A better estimate can be calculated using RATE function [2].
Also, in the original formula the absolute value of diff need to be taken to avoid getting negative rate impacting the avg and other stats for Time to drain metric. Time to drain can't be negative, if there is no message it will be 0 but current formula adds negative datapoints (though the visibility is capped at 0 min but datapoint are still negative) and which reduces the avg .
Version
v5.2.3
Steps and/or minimal code example to reproduce
It is not actually a bug but a better and simpler computation exist. Currently, time to drain metrics in SQS is calculated as below [1] , which is indirect. A better estimate can be calculated using RATE function [2].
cdk-monitoring-constructs/lib/monitoring/aws-sqs/SqsQueueMetricFactory.ts
Lines 82 to 92 in 81f0c6b
Expected behavior
Instead of directly getting the consumption rate, current computation estimate based on different metrics which is less accurate.
Actual behavior
A better and direct method can be used.
Other details
A sample code for this is
The text was updated successfully, but these errors were encountered: