Elastic APM Java Annotation API

Thank you very much Felix, we got it working now.

We have a follow up question on @CaptureSpan.

When we are using @CaptureSpan, we notice that each child span graph extends all the way to the end of the transaction, even if we explicitly call end() for each annotated method.

If we are using ElasticApm.createSpan() from the parent span, each method we have a trace on correctly captures the span graph as a waterfall diagram.

It's something like this:

Annotation

Code-only

Is this expected behaviour?