diff --git a/instrumentation/graphql-java/graphql-java-20.0/library/src/main/java/io/opentelemetry/instrumentation/graphql/v20_0/GraphqlInstrumenterFactory.java b/instrumentation/graphql-java/graphql-java-20.0/library/src/main/java/io/opentelemetry/instrumentation/graphql/v20_0/GraphqlInstrumenterFactory.java index dd3ae5f114ab..d1391ecde059 100644 --- a/instrumentation/graphql-java/graphql-java-20.0/library/src/main/java/io/opentelemetry/instrumentation/graphql/v20_0/GraphqlInstrumenterFactory.java +++ b/instrumentation/graphql-java/graphql-java-20.0/library/src/main/java/io/opentelemetry/instrumentation/graphql/v20_0/GraphqlInstrumenterFactory.java @@ -8,7 +8,6 @@ import graphql.schema.DataFetchingEnvironment; import io.opentelemetry.api.OpenTelemetry; import io.opentelemetry.instrumentation.api.instrumenter.Instrumenter; -import io.opentelemetry.instrumentation.api.instrumenter.SpanStatusExtractor; import io.opentelemetry.instrumentation.graphql.internal.OpenTelemetryInstrumentationHelper; final class GraphqlInstrumenterFactory { @@ -28,10 +27,6 @@ static Instrumenter createDataFetcherInstrumenter INSTRUMENTATION_NAME, environment -> environment.getExecutionStepInfo().getField().getName()) .addAttributesExtractor(new GraphqlDataFetcherAttributesExtractor()) - .setSpanStatusExtractor( - (spanStatusBuilder, environment, unused, error) -> - SpanStatusExtractor.getDefault() - .extract(spanStatusBuilder, environment, null, error)) .setEnabled(enabled) .buildInstrumenter(); }