Skip to content

Opamp first iteration completion #2067

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

Open
wants to merge 14 commits into
base: main
Choose a base branch
from

Conversation

LikeTheSalad
Copy link
Contributor

@LikeTheSalad LikeTheSalad commented Jul 30, 2025

Finishes the first iteration of the opamp-client module by addressing these issues: #1902, #1956, and #1954.

The issue #1902 is partially done, as it was about updating both the OpampClient and RequestService implementations to extend Closeable. However, this was only feasible for OpampClient, as doing so for RequestService required keeping its abstraction within OpampClientImpl, leading to having to use factories and extra steps to keep it generic. In the end, it was a lot of code changes that didn't seem feasible for this PR.

The following changes have been added as well:

  • Updating the README file to include a usage example.
  • Applying the maven publishing conventions.
  • Suppressing auto instrumentation of the opamp-related HTTP requests.

@LikeTheSalad
Copy link
Contributor Author

cc @tigrannajaryan

@LikeTheSalad LikeTheSalad changed the title Opamp first iteration polishing Opamp first iteration completion Jul 30, 2025
@tigrannajaryan
Copy link
Member

@LikeTheSalad thanks for making progress on this.

Once it is sufficiently complete we should also look into setting up interoperability tests that verify that Java and Go implementations can work together.

Comment on lines 21 to 24
// Attaching animalsniffer check to the compilation process.
tasks.named("classes").configure {
finalizedBy("animalsnifferMain")
}
Copy link
Contributor

Choose a reason for hiding this comment

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

opentelemetry-java and opentelemetry-java-instrumentation don't have this

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Got it. It's just a way of getting notified of an api compatibility issue during development without having to run all the build checks, though it's not strictly necessary, so I've just removed it.

Copy link
Contributor

Choose a reason for hiding this comment

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

I don't have anything particular against it just that it would be preferable to have this aligned with our other repositories.

@@ -45,8 +47,14 @@ public CompletableFuture<Response> send(BodyWriter writer, int contentLength) {
RequestBody body = new RawRequestBody(writer, contentLength, MEDIA_TYPE);
builder.post(body);

InstrumentationUtil.suppressInstrumentation(() -> doSendRequest(builder.build(), future));
Copy link
Contributor

Choose a reason for hiding this comment

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

Perhaps there should be a comment explaining that this prevents automatic instrumentation from tracing the underlying okhttp request?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Sure. I've just added a comment.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants