Skip to content

Commit

Permalink
update README (move Span Name section)
Browse files Browse the repository at this point in the history
Signed-off-by: Sergei Malafeev <sergeymalafeev@gmail.com>
  • Loading branch information
malafeev committed Jun 28, 2018
1 parent 29a8dbf commit a671c1a
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,16 +41,6 @@ Tracer tracer = ...

```

### Span Name
By default, span names are set to the operation performed by the Jedis object. To customize the span name, provide a Function to the Jedis object that alters the span name. If a function is not provided, the span name will remain the default. Refer to the RedisSpanNameProvider class for a function that prefixes the operation name.
```java
//Create Tracing Jedis with custom span name
Jedis jedis = new TracingJedis(tracer, false, RedisSpanNameProvider.PREFIX_OPERATION_NAME("redis.");
jedis.set("foo", "bar");
//Span name is now set to "redis.set"

```

### Jedis
```java

Expand Down Expand Up @@ -91,6 +81,16 @@ try (Jedis jedis = pool.getResource()) {
}
```

### Jedis Span Name
By default, span names are set to the operation performed by the Jedis object. To customize the span name, provide a Function to the Jedis object that alters the span name. If a function is not provided, the span name will remain the default. Refer to the RedisSpanNameProvider class for a function that prefixes the operation name.
```java
//Create Tracing Jedis with custom span name
Jedis jedis = new TracingJedis(tracer, false, RedisSpanNameProvider.PREFIX_OPERATION_NAME("redis.");
jedis.set("foo", "bar");
//Span name is now set to "redis.set"

```

### Lettuce

```java
Expand Down

0 comments on commit a671c1a

Please sign in to comment.