Skip to content

Commit 9cfd9e4

Browse files
committed
Migrating TapirPathInstrumentation
1 parent aa63bb7 commit 9cfd9e4

File tree

1 file changed

+4
-3
lines changed
  • instrumentation/pekko/pekko-http-1.0/javaagent/src/main/java/io/opentelemetry/javaagent/instrumentation/pekkohttp/v1_0/server/tapir

1 file changed

+4
-3
lines changed

instrumentation/pekko/pekko-http-1.0/javaagent/src/main/java/io/opentelemetry/javaagent/instrumentation/pekkohttp/v1_0/server/tapir/TapirPathInstrumentation.java

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,11 +35,12 @@ public void transform(TypeTransformer transformer) {
3535

3636
@SuppressWarnings("unused")
3737
public static class ApplyAdvice {
38+
@Advice.AssignReturned.ToReturned
3839
@Advice.OnMethodExit(onThrowable = Throwable.class, suppress = Throwable.class)
39-
public static void onExit(
40+
public static Object onExit(
4041
@Advice.Argument(0) ServerEndpoint<?, ?> endpoint,
41-
@Advice.Return(readOnly = false) Function1<RequestContext, Future<RouteResult>> route) {
42-
route = new RouteWrapper(endpoint, route);
42+
@Advice.Return Function1<RequestContext, Future<RouteResult>> route) {
43+
return new RouteWrapper(endpoint, route);
4344
}
4445
}
4546
}

0 commit comments

Comments
 (0)