Skip to content
This repository has been archived by the owner on May 23, 2023. It is now read-only.

Commit

Permalink
Add service tag
Browse files Browse the repository at this point in the history
Signed-off-by: Pavol Loffay <[email protected]>
  • Loading branch information
pavolloffay committed Jul 13, 2018
1 parent 67f080c commit 9a86782
Showing 1 changed file with 14 additions and 1 deletion.
15 changes: 14 additions & 1 deletion opentracing-api/src/main/java/io/opentracing/tag/Tags.java
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,17 @@ private Tags() {
*/
public static final String SPAN_KIND_CONSUMER = "consumer";

/**
* The service name for a span, which overrides any default "service name" property defined
* in a tracer's config. This tag is meant to only be used when a tracer is reporting spans
* on behalf of another service (for example, a service mesh reporting on behalf of the services
* it is proxying). This tag does not need to be used when reporting spans for the service the
* tracer is running in.
*
* @see #PEER_SERVICE
*/
public static final StringTag SERVICE = new StringTag("service");

/**
* HTTP_URL records the url of the incoming request.
*/
Expand All @@ -71,7 +82,9 @@ private Tags() {
public static final StringTag PEER_HOST_IPV6 = new StringTag("peer.ipv6");

/**
* PEER_SERVICE records the service name of the peer.
* PEER_SERVICE records the service name of the peer service.
*
* @see #SERVICE
*/
public static final StringTag PEER_SERVICE = new StringTag("peer.service");

Expand Down

0 comments on commit 9a86782

Please sign in to comment.