Courseiva

Google ACE Practice Question: Ensuring Successful Operation of a Cloud Solution

Your team uses Cloud Logging to store application logs. You want to create a metric that counts the number of ERROR log entries per service. Which type of log-based metric should you create?

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

Counter metric

Log-based metrics can be counter metrics (count of log entries matching a filter) or distribution metrics. For counting occurrences, a counter metric is appropriate.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • Distribution metric

    Why it's wrong here

    Distribution metrics in Cloud Logging are designed for extracting numeric values from log entries, such as request latency or payload size, and then aggregating them into a histogram of value buckets. They do not simply count matching log entries; for a count of errors, a distribution would be overkill and actually inapplicable because there is no numeric value being measured. Therefore, a distribution metric is not the correct type for counting logs with severity=ERROR.

  • Boolean metric

    Why it's wrong here

    Boolean metrics are not a recognized type in Cloud Logging's log-based metrics system; the supported types are counter, distribution, and the user-defined metrics created via the Monitoring API. A boolean value would represent a true/false condition rather than a cumulative count, and log-based metrics do not provide a boolean aggregation type for counting occurrences. Thus, selecting a boolean metric is incorrect for counting ERROR-severity log entries.

  • Counter metric

    Why this is correct

    A counter metric is the correct log-based metric type for this use case, because it increments by one for every log entry that matches the specified filter, such as severity=ERROR. This gives the total number of error logs over the selected time window, which is exactly what the team wants to track. In Cloud Logging, you define a counter-based log metric with a filter and then use it in Monitoring charts or alerts.

  • Gauge metric

    Why it's wrong here

    Gauge metrics do exist in Cloud Monitoring as user-defined metric types that report a numeric value representing a current condition, such as CPU utilization or temperature, at each reporting interval. However, they are not a supported type for log-based metrics, nor do they accumulate a count over time; a gauge would require a numeric extracted value, not a count of raw log entries. Therefore, a gauge metric is not suitable for counting ERROR logs and is fundamentally different from a counter.

About these practice questions

This ACE question is part of Courseiva's 769-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam dumps. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This ACE practice question is part of Courseiva's free Google Cloud certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the ACE exam.