diff --git a/docs/src/main/asciidoc/spring-cloud-sleuth.adoc b/docs/src/main/asciidoc/spring-cloud-sleuth.adoc index ab722bd7e..2d13812d3 100644 --- a/docs/src/main/asciidoc/spring-cloud-sleuth.adoc +++ b/docs/src/main/asciidoc/spring-cloud-sleuth.adoc @@ -751,6 +751,22 @@ error callbacks takes care of closing client side spans. IMPORTANT: You have to register `WebClient` as a bean so that the tracing instrumention gets applied. If you create a `WebClient` instance with a `new` keyword then the instrumentation WILL NOT work. +==== Traverson + +If you're using the http://docs.spring.io/spring-hateoas/docs/current/reference/html/#client.traverson[Traverson] library +it's enough for you to inject a `RestTemplate` as a bean into your Traverson object. Since `RestTemplate` +is already intercepted, you will get full support of tracing in your client. Below you can find a pseudo code +of how to do that: + +[source,java] +---- +@Autowired RestTemplate restTemplate; + +Traverson traverson = new Traverson(URI.create("http://some/address"), + MediaType.APPLICATION_JSON, MediaType.APPLICATION_JSON_UTF8).setRestOperations(restTemplate); +// use Traverson +---- + === Feign By default Spring Cloud Sleuth provides integration with feign via the `TraceFeignClientAutoConfiguration`. You can disable it entirely