private void appendAttachedEventsToSpanDebuggable(List<Span> spans, List<SWSpanAttachedEventRecord> events) throws InvalidProtocolBufferException {
        DebuggingTraceContext traceContext = DebuggingTraceContext.TRACE_CONTEXT.get();
        DebuggingSpan debuggingSpan = null;
        try {
            if (traceContext != null) {
                debuggingSpan = traceContext.createSpan("Query Service : appendAttachedEventsToSpan");
            }
            appendAttachedEventsToSpan(spans, events);
        } finally {
            if (traceContext != null && debuggingSpan != null) {
                traceContext.stopSpan(debuggingSpan);

            }
        }
    }
@param duration nullable unless for BanyanDB query from cold stage
oap-server/server-core/src/main/java/org/apache/skywalking/oap/server/core/query/TraceQueryService.java