Skip to content

Implement a retry policy decorator to handle Internal errors in tests #5852

@haphungw

Description

@haphungw

In #5851, we added manual retry logic inside try_get_metric to catch and ignore transient Code::Internal and Code::NotFound errors from the Cloud Monitoring backend.

While this works for now to reduce test flakiness, we should implement a proper retry policy decorator that can automatically wrap these API calls and handle transient errors (like Internal) under the hood.

See #5851 (review)

Metadata

Metadata

Assignees

No one assigned

    Labels

    type: feature request‘Nice-to-have’ improvement, new feature or different behavior or design.

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions