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

chore(storage): add retry metric headers #6013

Merged
merged 10 commits into from
May 18, 2022
Merged

Conversation

tritone
Copy link
Contributor

@tritone tritone commented May 6, 2022

Adds retry metrics to X-Goog-Api-Client header.

Format will be:
X-Goog-Api-Client: gccl-invocation-id/7a808dc9-2865-4777-beee-cf8259ef7fe0 gccl-attempt-count/1 gl-go/1.18.0 gccl/1.22.0

Does not include uploads & downloads, or experimental gRPC methods. Support for these will be added later.

@product-auto-label product-auto-label bot added size: s Pull request size is small. api: storage Issues related to the Cloud Storage API. labels May 6, 2022
@product-auto-label product-auto-label bot added size: m Pull request size is medium. and removed size: s Pull request size is small. labels May 9, 2022
@tritone tritone changed the title chore(storage): add retry metric headers [WIP] chore(storage): add retry metric headers May 9, 2022
@tritone tritone marked this pull request as ready for review May 9, 2022 20:15
@tritone tritone requested review from a team as code owners May 9, 2022 20:15
storage/invoke.go Outdated Show resolved Hide resolved
@codyoss
Copy link
Member

codyoss commented May 16, 2022

Do we have these new headers documented internally? Are they already standardized? If not I am not sure we should add things to this header without more convo

@tritone
Copy link
Contributor Author

tritone commented May 16, 2022

Do we have these new headers documented internally? Are they already standardized? If not I am not sure we should add things to this header without more convo

Yes, this has already been standardized and approved internally. Will send you a doc.

@tritone tritone requested a review from noahdietz May 16, 2022 19:34
Copy link

@unforced unforced left a comment

Choose a reason for hiding this comment

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

This is looking good to me, although I'd wait for Denis' eyes on it as he probably knows golang better than I do.

storage/invoke_test.go Outdated Show resolved Hide resolved
@tritone tritone enabled auto-merge (squash) May 18, 2022 16:07
@tritone tritone merged commit 20e9b2a into googleapis:main May 18, 2022
@tritone tritone deleted the retry-metric branch May 18, 2022 16:24
tritone added a commit to tritone/google-api-go-client that referenced this pull request Jun 10, 2022
Adds invocation ID and attempt count to x-goog-api-client header
for simple and resumable uploads.

Note that this will also add this information to chunk upload
requests for individual chunks for BQ and other APIs that do uploads
using gensupport as well. Hopefully this isn't an issue.

Similar to googleapis/google-cloud-go#6013
tritone added a commit to googleapis/google-api-go-client that referenced this pull request Jun 21, 2022
Adds invocation ID and attempt count to x-goog-api-client header
for simple and resumable uploads.

Note that this will also add this information to chunk upload
requests for individual chunks for BQ and other APIs that do uploads
using gensupport as well. Hopefully this isn't an issue.

Similar to googleapis/google-cloud-go#6013
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. size: m Pull request size is medium.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants