locate: retry on ErrClientGetResourceGroup for transient errors
When receiving ErrClientGetResourceGroup error, distinguish between permanent and transient errors:
- For 'resource group not found' error, return directly without retry since it's a permanent error
- For other errors (e.g., 'not leader'), apply backoff and retry since they are transient errors
Add test case TestOnSendFailByResourceGroupError to cover both scenarios:
- Test that 'resource group not found' returns immediately without backoff
- Test that other errors trigger retry with backoff
@ystaticy: adding LGTM is restricted to approvers and reviewers in OWNERS files.
In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.
[APPROVALNOTIFIER] This PR is APPROVED
This pull-request has been approved by: iosmanthus, ystaticy
The full list of commands accepted by this bot can be found here.
The pull request process is described here
- ~~OWNERS~~ [iosmanthus]
Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment
[LGTM Timeline notifier]
Timeline:
2025-10-22 06:12:08.888394831 +0000 UTC m=+852234.965647391: :ballot_box_with_check: agreed by iosmanthus.