@Override public void addMessageEvent(io.opencensus.trace.MessageEvent messageEvent) { Preconditions.checkNotNull(messageEvent, "messageEvent"); synchronized (this) { if (hasBeenEnded) { logger.log(Level.FINE, "Calling addNetworkEvent() on an ended Span."); return; } getInitializedNetworkEvents() .addEvent( new EventWithNanoTime<io.opencensus.trace.MessageEvent>( clock.nowNanos(), checkNotNull(messageEvent, "networkEvent"))); } }
@Override public void addAnnotation(String description, Map<String, AttributeValue> attributes) { Preconditions.checkNotNull(description, "description"); Preconditions.checkNotNull(attributes, "attribute"); synchronized (this) { if (hasBeenEnded) { logger.log(Level.FINE, "Calling addAnnotation() on an ended Span."); return; } getInitializedAnnotations() .addEvent( new EventWithNanoTime<Annotation>( clock.nowNanos(), Annotation.fromDescriptionAndAttributes(description, attributes))); } }
@Override public void addAnnotation(String description, Map<String, AttributeValue> attributes) { Preconditions.checkNotNull(description, "description"); Preconditions.checkNotNull(attributes, "attribute"); synchronized (this) { if (hasBeenEnded) { logger.log(Level.FINE, "Calling addAnnotation() on an ended Span."); return; } getInitializedAnnotations() .addEvent( new EventWithNanoTime<Annotation>( clock.nowNanos(), Annotation.fromDescriptionAndAttributes(description, attributes))); } }
@Override public void addMessageEvent(io.opencensus.trace.MessageEvent messageEvent) { Preconditions.checkNotNull(messageEvent, "messageEvent"); synchronized (this) { if (hasBeenEnded) { logger.log(Level.FINE, "Calling addNetworkEvent() on an ended Span."); return; } getInitializedNetworkEvents() .addEvent( new EventWithNanoTime<io.opencensus.trace.MessageEvent>( clock.nowNanos(), checkNotNull(messageEvent, "networkEvent"))); } }
@Override public void addAnnotation(Annotation annotation) { Preconditions.checkNotNull(annotation, "annotation"); synchronized (this) { if (hasBeenEnded) { logger.log(Level.FINE, "Calling addAnnotation() on an ended Span."); return; } getInitializedAnnotations() .addEvent(new EventWithNanoTime<Annotation>(clock.nowNanos(), annotation)); } }
@Override public void addAnnotation(Annotation annotation) { Preconditions.checkNotNull(annotation, "annotation"); synchronized (this) { if (hasBeenEnded) { logger.log(Level.FINE, "Calling addAnnotation() on an ended Span."); return; } getInitializedAnnotations() .addEvent(new EventWithNanoTime<Annotation>(clock.nowNanos(), annotation)); } }