-
Notifications
You must be signed in to change notification settings - Fork 77
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
feat: introductory beta level support for OpenTelemetry tracing on c.g.c.storage.Storage methods #2837
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
* feat: Add OpenTelemetry to GRPC * adding rpc.system value * refactor test for both transports * lint * add branch protection rules to otel feature branch * pr comment
* feat: Instrument HTTP Reads and Writes
* feat: instrument HTTP readAllBytes
* feat: Instrument HTTP createFrom * make exception handling more generic
* feat: Instrument Reader and Writer methods
product-auto-label
bot
added
size: xl
Pull request size is extra large.
api: storage
Issues related to the googleapis/java-storage API.
labels
Dec 6, 2024
BenWhitehead
added
the
do not merge
Indicates a pull request not ready for merge, due to either quality or timing.
label
Dec 9, 2024
sydney-munro
added
the
kokoro:force-run
Add this label to force Kokoro to re-run the tests.
label
Dec 17, 2024
yoshi-kokoro
removed
the
kokoro:force-run
Add this label to force Kokoro to re-run the tests.
label
Dec 17, 2024
sydney-munro
removed
the
do not merge
Indicates a pull request not ready for merge, due to either quality or timing.
label
Dec 17, 2024
sydney-munro
added
the
kokoro:force-run
Add this label to force Kokoro to re-run the tests.
label
Dec 17, 2024
yoshi-kokoro
removed
the
kokoro:force-run
Add this label to force Kokoro to re-run the tests.
label
Dec 17, 2024
sydney-munro
changed the title
Feat: OpenTelemetry Trace Support
feat: OpenTelemetry Trace Support
Dec 17, 2024
BenWhitehead
requested changes
Dec 18, 2024
google-cloud-storage/src/main/java/com/google/cloud/storage/GrpcStorageOptions.java
Outdated
Show resolved
Hide resolved
google-cloud-storage/src/main/java/com/google/cloud/storage/GrpcStorageOptions.java
Outdated
Show resolved
Hide resolved
google-cloud-storage/src/main/java/com/google/cloud/storage/HttpStorageOptions.java
Outdated
Show resolved
Hide resolved
google-cloud-storage/src/main/java/com/google/cloud/storage/HttpStorageOptions.java
Outdated
Show resolved
Hide resolved
google-cloud-storage/src/main/java/com/google/cloud/storage/HttpStorageOptions.java
Outdated
Show resolved
Hide resolved
google-cloud-storage/src/test/java/com/google/cloud/storage/ITOpenTelemetryTest.java
Outdated
Show resolved
Hide resolved
google-cloud-storage/src/test/java/com/google/cloud/storage/ITOpenTelemetryTest.java
Outdated
Show resolved
Hide resolved
google-cloud-storage/src/test/java/com/google/cloud/storage/ITOpenTelemetryTest.java
Outdated
Show resolved
Hide resolved
google-cloud-storage/src/test/java/com/google/cloud/storage/it/runner/registry/TestBench.java
Outdated
Show resolved
Hide resolved
google-cloud-storage/src/test/java/com/google/cloud/storage/otel/TestExporter.java
Outdated
Show resolved
Hide resolved
… in method modification (#2856) Refactor com.google.cloud.storage.Storage otel tracing to be based on a decorating instance of Storage rather than modifying the implementations of StorageImpl and GrpcStorageImpl directly. This simplifies things by ensuring any otel tracing for c.g.c.s.Storage is implemented for both http and grpc at the same time and with the same metadata. As a side effect, the previous com.google.cloud.storage.otel package has been removed. The number of lines appears daunting, however a high level overview of the actual modifications: 1. Remove otel tracing from StorageImpl 2. Remove otel tracing from GrpcStorageImpl 3. Cleanup StorageOption 1. classes to specify `@BetaApi` on all otel related methods 2. Add `{Http,Grpc}StorageDefaults.getDefaultOpenTelemetry` default which points at `OpenTelemetry.noop()` 3. Relax dependency on OpenTelemetrySdk to only OpenTelemetry 4. Add OtelStorageDecorator (~1700 Lines of the PR) to decorate nearly all public api methods (excluding batch()) * Each method is "logicless" for the most part, and was generated with the help of IntelliJ live templates * Each method is generally: Define span, and scope invoke delegate catch any exception and complete the span * There are sub decorators for ReadChannel, WriteChannel, BlobWriteSession and CopyWriter which carry the originating span along for their lifetimes 5. Remote `com.google.cloud.storage.otel` package and helpers 6. Update assertions in ITOpenTelemetryTest to be wrapped in an `assertAll`
BenWhitehead
changed the title
feat: OpenTelemetry Trace Support
feat: introductory beta level support for OpenTelemetry tracing on c.g.c.storage.Storage methods
Jan 6, 2025
BenWhitehead
approved these changes
Jan 6, 2025
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 googleapis/java-storage API.
size: xl
Pull request size is extra large.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Introducing OpenTelemetry Tracing