Interface RetrievedTrace.Builder

    • Method Detail

      • id

        RetrievedTrace.Builder id​(String id)

        The unique identifier for the span.

        Parameters:
        id - The unique identifier for the span.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • duration

        RetrievedTrace.Builder duration​(Double duration)

        The length of time in seconds between the start time of the root span and the end time of the last span that completed.

        Parameters:
        duration - The length of time in seconds between the start time of the root span and the end time of the last span that completed.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • spans

        RetrievedTrace.Builder spans​(Collection<Span> spans)

        Spans that comprise the trace.

        Parameters:
        spans - Spans that comprise the trace.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • spans

        RetrievedTrace.Builder spans​(Span... spans)

        Spans that comprise the trace.

        Parameters:
        spans - Spans that comprise the trace.
        Returns:
        Returns a reference to this object so that method calls can be chained together.
      • spans

        RetrievedTrace.Builder spans​(Consumer<Span.Builder>... spans)

        Spans that comprise the trace.

        This is a convenience method that creates an instance of the Span.Builder avoiding the need to create one manually via Span.builder().

        When the Consumer completes, SdkBuilder.build() is called immediately and its result is passed to #spans(List).

        Parameters:
        spans - a consumer that will call methods on Span.Builder
        Returns:
        Returns a reference to this object so that method calls can be chained together.
        See Also:
        #spans(java.util.Collection)