Skip to content
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

Convert all remaining database client decorators to tracers #1236

Merged
merged 9 commits into from
Sep 23, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@

import io.grpc.Context;
import io.opentelemetry.OpenTelemetry;
import io.opentelemetry.context.Scope;
import io.opentelemetry.instrumentation.api.InstrumentationVersion;
import io.opentelemetry.trace.EndSpanOptions;
import io.opentelemetry.trace.Span;
Expand Down Expand Up @@ -61,6 +62,10 @@ public Span startSpan(String spanName, Kind kind) {
return tracer.spanBuilder(spanName).setSpanKind(kind).startSpan();
}

public Scope startScope(Span span) {
return tracer.withSpan(span);
}

iNikem marked this conversation as resolved.
Show resolved Hide resolved
public Span getCurrentSpan() {
return tracer.getCurrentSpan();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -82,12 +82,6 @@ public Span getClientSpan() {
return CONTEXT_CLIENT_SPAN_KEY.get(context);
}

// TODO make abstract when implemented in all subclasses
@Override
protected String getInstrumentationName() {
return null;
}

@Override
public void end(Span span) {
span.end();
Expand Down

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ public String[] helperClassNames() {
"io.opentelemetry.instrumentation.auto.rxjava.SpanFinishingSubscription",
"io.opentelemetry.instrumentation.auto.rxjava.TracedSubscriber",
"io.opentelemetry.instrumentation.auto.rxjava.TracedOnSubscribe",
packageName + ".CouchbaseClientDecorator",
packageName + ".CouchbaseClientTracer",
packageName + ".CouchbaseOnSubscribe",
};
}
Expand Down

This file was deleted.

Loading