Answer – D
Our scenario states that we are receiving HTTP Error 504 intermittently. The scenario requires that the ALARM should trigger ONLY if it breaches 2 evaluation periods.
None of the options listed is a good choice.
When you create an alarm, you specify three settings to enable CloudWatch to evaluate when to change the alarm state:
Period is the length of time to evaluate the metric to create each individual data point for a metric. It is expressed in seconds. If you choose one minute as the period, there is one data point every minute.
Evaluation Period is the number of the most recent data points to evaluate when determining alarm state.
Datapoints to Alarm is the number of data points within the evaluation period that must be breached to cause the alarm to go to the ALARM state. The breaching data points do not have to be consecutive. They must all be within the last number of data points equal to the Evaluation Period.
Let us look at an example.
In the following figure, the alarm threshold is set to three units. The alarm is configured to go to the ALARM state, and both Evaluation Period and Datapoints to Alarm are 3. That is, when all three data points in the most recent three consecutive periods are above the threshold, the alarm goes to the ALARM state. In the figure, this happens in the third through fifth time periods. At period six, the value dips below the threshold, so one of the periods being evaluated is not breaching, and the alarm state changes to OK. During the ninth time period, the threshold is breached again, but for only one period. Consequently, the alarm state remains OK.
Option A is incorrect since here there is no mention of any special kind of notification.
Option B is incorrect since you don’t need to mention a 0 value. Place a 1 value when the result is received.
Option C is incorrect since there is no mention of the frequency, so we don’t know if we need high resolution for metrics.
For more information on the aggregation of data in Cloudwatch, please refer to the below Link-
https://docs.aws.amazon.com/AmazonCloudWatch/latest/monitoring/CloudWatch-Agent-common-scenarios.html#CloudWatch-Agent-aggregating-metrics