예제 #1
0
 def user_span(self, span_type):
     """
     A wrapper around the Span context manager that sets the emitter to be
     appending to self.spans and sets span type to custom and the user
     specified span type as the label tag.
     """
     span = Span(self.spans.append, "custom")
     span.set_tag("label", span_type)
     return span
예제 #2
0
 def span(self, span_type):
     """
     A wrapper around the Span context manager that sets the emitter to be
     appending to self.spans
     """
     return Span(self.spans.append, span_type)