Top Description Methods
io.micrometer.tracing.annotation

public @Interface NewSpan

extends Annotation
Annotations
@Retention:RUNTIME
@Inherited
@Target:METHOD
Imports
java.lang.annotation.ElementType, .Inherited, .Retention, .RetentionPolicy, .Target

Allows to create a new span around a public method. The new span will be either a child of an existing span if a trace is already in progress or a new span will be created if there was no previous trace.

Method parameters can be annotated with SpanTag, which will end in adding the parameter value as a tag value to the span. The tag key will be the value of the key annotation from SpanTag.

Author
Christian Schwerdtfeger
Since
1.0.0

Method Summary

Modifier and TypeMethod and Description
public String

Returns:

the name of the span which will be created
name
()

The name of the span which will be created.

public String

Returns:

the name of the span which will be created
value
()

The name of the span which will be created.

Inherited from java.lang.annotation.Annotation:
annotationTypeequalshashCodetoString

Method Detail

nameback to summary
public String name()

The name of the span which will be created. Default is the annotated method's name separated by hyphens.

Returns:String

the name of the span which will be created

valueback to summary
public String value()

The name of the span which will be created. Default is the annotated method's name separated by hyphens.

Returns:String

the name of the span which will be created