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

impl(storage): use CurrentOptions() for RetryClient #9230

Merged

Conversation

coryan
Copy link
Contributor

@coryan coryan commented Jun 8, 2022

The most interesting options in this case are the RetryPolicyOption
and BackoffPolicyOption.

Because now the policies are obtained from the CurrentOptions() and
these are initialized from mock->options(), the mocks need to return
sensible values for the options.

Some tests need to set the OptionsSpan, or the unit under test will not
work.

Part of the work for #7691


This change is Reviewable

The most interesting options in this case are the `RetryPolicyOption`
and `BackoffPolicyOption`.

Because now the policies are obtained from the `CurrentOptions()` and
these are initialized from `mock->options()`, the mocks need to return
sensible values for the options.

Some tests need to set the OptionsSpan, or the unit under test will not
work.
@product-auto-label product-auto-label bot added the api: storage Issues related to the Cloud Storage API. label Jun 8, 2022
@google-cloud-cpp-bot
Copy link
Collaborator

Google Cloud Build Logs
For commit: a16f98da27375098836cc445aceeb388984390e7

ℹ️ NOTE: Kokoro logs are linked from "Details" below.

@codecov
Copy link

codecov bot commented Jun 9, 2022

Codecov Report

Merging #9230 (cf547ff) into main (cf547ff) will not change coverage.
The diff coverage is n/a.

❗ Current head cf547ff differs from pull request most recent head a16f98d. Consider uploading reports for the commit a16f98d to get more accurate results

@@           Coverage Diff           @@
##             main    #9230   +/-   ##
=======================================
  Coverage   94.54%   94.54%           
=======================================
  Files        1455     1455           
  Lines      131248   131248           
=======================================
  Hits       124084   124084           
  Misses       7164     7164           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update cf547ff...a16f98d. Read the comment docs.

@coryan coryan marked this pull request as ready for review June 9, 2022 00:44
@coryan coryan requested a review from a team as a code owner June 9, 2022 00:44
Copy link
Member

@scotthart scotthart left a comment

Choose a reason for hiding this comment

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

Reviewed 11 of 11 files at r1, all commit messages.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on @coryan)

@coryan coryan merged commit 99685e3 into googleapis:main Jun 9, 2022
@coryan coryan deleted the feat-storage-per-operation-options-pr8 branch June 9, 2022 20:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api: storage Issues related to the Cloud Storage API.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants