Skip to content

Commit

Permalink
Enable instrumentation by default
Browse files Browse the repository at this point in the history
  • Loading branch information
JonasKunz committed Jan 20, 2025
1 parent 7fce2e2 commit 572fd04
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 7 deletions.
2 changes: 1 addition & 1 deletion docs/configure.md
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ It supports:
* Tracing for requests, including GenAI-specific attributes such as token usage
* Opt-In logging of OpenAI request and response content payloads

This instrumentation is currently **experimental**. It needs to be explicitly enabled by setting either the `OTEL_INSTRUMENTATION_OPENAI_CLIENT_ENABLED` environment variable or the `otel.instrumentation.openai-client.enabled` JVM property to `true`.
This instrumentation is currently **experimental**. It can by disabled by setting either the `OTEL_INSTRUMENTATION_OPENAI_CLIENT_ENABLED` environment variable or the `otel.instrumentation.openai-client.enabled` JVM property to `false`.

In addition, this instrumentation provides the following configuration options:

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@
import com.google.auto.service.AutoService;
import io.opentelemetry.javaagent.extension.instrumentation.InstrumentationModule;
import io.opentelemetry.javaagent.extension.instrumentation.TypeInstrumentation;
import io.opentelemetry.sdk.autoconfigure.spi.ConfigProperties;
import java.util.Collections;
import java.util.List;

Expand All @@ -33,11 +32,6 @@ public OpenAiClientInstrumentationModule() {
super(Constants.INSTRUMENTATION_NAME);
}

@Override
public boolean defaultEnabled(ConfigProperties config) {
return false;
}

@Override
public List<TypeInstrumentation> typeInstrumentations() {
return Collections.singletonList(new OpenAiOkHttpClientBuilderInstrumentation());
Expand Down

0 comments on commit 572fd04

Please sign in to comment.