Skip to content

Commit

Permalink
fix: Add the deprecation notice for tracing enable/disable option. (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
ehsannas authored Oct 17, 2024
1 parent 26c4cbd commit d213245
Showing 1 changed file with 13 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,13 @@ public class FirestoreOpenTelemetryOptions {
this.openTelemetry = builder.openTelemetry;
}

/**
* @deprecated This method will be removed in the next minor version update. Please use a no-op
* TracerProvider or set the environment variable `FIRESTORE_ENABLE_TRACING=OFF` to disable
* tracing. If the GlobalOpenTelemetry or the OpenTelemetry instance passed to Firestore
* contain a valid TracerProvider, the Firestore client will generate spans by utilizing it.
*/
@Deprecated
public boolean isTracingEnabled() {
return tracingEnabled;
}
Expand Down Expand Up @@ -78,7 +85,13 @@ public FirestoreOpenTelemetryOptions build() {
* Sets whether tracing should be enabled.
*
* @param tracingEnabled Whether tracing should be enabled.
* @deprecated This method will be removed in the next minor version update. Please use a no-op
* TracerProvider or set the environment variable `FIRESTORE_ENABLE_TRACING=OFF` to disable
* tracing. If the GlobalOpenTelemetry or the OpenTelemetry instance passed to Firestore
* contains a valid TracerProvider, the Firestore client will generate spans by utilizing
* it.
*/
@Deprecated
@Nonnull
public FirestoreOpenTelemetryOptions.Builder setTracingEnabled(boolean tracingEnabled) {
this.tracingEnabled = tracingEnabled;
Expand Down

0 comments on commit d213245

Please sign in to comment.