Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🌱 exponential retry on name resolution to registries #1576

Merged

Conversation

grokspawn
Copy link
Contributor

Resolves #1513

extends the existing exponential fallback strategy to include initial name resolution to the registry.

Description of the change:

Motivation for the change:

Reviewer Checklist

  • Implementation matches the proposed design, or proposal is updated to match implementation
  • Sufficient unit test coverage
  • Sufficient end-to-end test coverage
  • Docs updated or added to /docs
  • Commit messages sensible and descriptive

@openshift-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Feb 10, 2025
Copy link

codecov bot commented Feb 10, 2025

Codecov Report

Attention: Patch coverage is 0% with 19 lines in your changes missing coverage. Please review.

Project coverage is 46.77%. Comparing base (81056f9) to head (eb9035c).
Report is 4 commits behind head on master.

Files with missing lines Patch % Lines
pkg/image/containerdregistry/registry.go 0.00% 19 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1576      +/-   ##
==========================================
+ Coverage   46.76%   46.77%   +0.01%     
==========================================
  Files         135      135              
  Lines       15776    15883     +107     
==========================================
+ Hits         7377     7429      +52     
- Misses       7358     7412      +54     
- Partials     1041     1042       +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

name, root, err := resolver.Resolve(ctx, ref.String())
if err != nil {
return fmt.Errorf("error resolving name for image ref %s: %v", ref.String(), err)
retryBackoff := wait.Backoff{
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do we care about unit testing the retry? might require some refactoring to pass in a mock Resolve though, eh? =S

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll leave it as a nit - otherwise lgtm =D

Copy link
Contributor Author

@grokspawn grokspawn Feb 11, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, I was taken aback, honestly, at the lack of utest in the area. My practical test? Download 32 catalog combinations multiple times.

Copy link
Contributor

openshift-ci bot commented Feb 11, 2025

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: grokspawn, perdasilva

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:
  • OWNERS [grokspawn,perdasilva]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@grokspawn grokspawn added this pull request to the merge queue Feb 11, 2025
Merged via the queue into operator-framework:master with commit 19a457e Feb 11, 2025
10 of 12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add retry support to resolving in opm alpha render-template
2 participants