diff --git a/1.0.x/images/dependencies.png b/1.0.x/images/dependencies.png index 324a10062..d0eceb6fb 100644 Binary files a/1.0.x/images/dependencies.png and b/1.0.x/images/dependencies.png differ diff --git a/1.0.x/images/zipkin-trace-screenshot.png b/1.0.x/images/zipkin-trace-screenshot.png index 61b7ff769..f0452f0f4 100644 Binary files a/1.0.x/images/zipkin-trace-screenshot.png and b/1.0.x/images/zipkin-trace-screenshot.png differ diff --git a/1.0.x/images/zipkin-traces.png b/1.0.x/images/zipkin-traces.png index 4875ca69b..673ece9aa 100644 Binary files a/1.0.x/images/zipkin-traces.png and b/1.0.x/images/zipkin-traces.png differ diff --git a/1.0.x/images/zipkin-ui.png b/1.0.x/images/zipkin-ui.png index ea99bc100..34b0215b7 100644 Binary files a/1.0.x/images/zipkin-ui.png and b/1.0.x/images/zipkin-ui.png differ diff --git a/1.0.x/index.html b/1.0.x/index.html index edbbd83cd..58b4f650a 100644 --- a/1.0.x/index.html +++ b/1.0.x/index.html @@ -428,9 +428,24 @@ body.book #toc,body.book #preamble,body.book h1.sect0,body.book .sect1>h2{page-b
1.1.0.BUILD-SNAPSHOT
+1.0.11.BUILD-SNAPSHOT
Spring Cloud Sleuth implements a distributed tracing solution for Spring Cloud.
@@ -1195,22 +1232,6 @@ public class ZipkinStreamServerApplication {Marcin Grzejszczak talking about Spring Cloud Sleuth and Zipkin
-PercentageBasedSampler is the default if you are using
spring-cloud-sleuth-zipkin or spring-cloud-sleuth-stream. You can
-configure the exports using spring.sleuth.sampler.percentage.
+configure the exports using spring.sleuth.sampler.percentage. The passed
+value needs to be a double from 0.0 to 1.0 so it’s not a percentage.
+For backwards compatibility reasons we’re not changing the property name.
For HTTP these are the beans responsible for creation of a Span from a HttpServletRequest
- and filling in the HttpServletResponse with tracing information.
For HTTP these are the beans responsible for creation of a Span from a HttpServletRequest.
@Bean
public SpanExtractor<HttpServletRequest> httpServletRequestSpanExtractor() {
...
-}
-
-@Bean
-public SpanInjector<HttpServletResponse> httpServletResponseSpanInjector() {
- ...
}
The following SpanInjector could be created
And you could register it like this:
+@Bean
+@Primary
+SpanExtractor<HttpServletRequest> customHttpServletRequestSpanExtractor() {
+ return new CustomHttpServletRequestSpanExtractor();
+}
+Spring Cloud Sleuth does not add trace/span related headers to the Http Response for security reasons. If you need the headers then a custom SpanInjector
+that injects the headers into the Http Response and a Servlet filter which makes use of this can be added the following way:
@Bean
-@Primary
-SpanExtractor<HttpServletRequest> customHttpServletRequestSpanExtractor() {
- return new CustomHttpServletRequestSpanExtractor();
+SpanInjector<HttpServletResponse> customHttpServletResponseSpanInjector() {
+ return new CustomHttpServletResponseSpanInjector();
}
@Bean
-@Primary
-SpanInjector<HttpServletResponse> customHttpServletResponseSpanInjector() {
- return new CustomHttpServletResponseSpanInjector();
+HttpResponseInjectingTraceFilter responseInjectingTraceFilter(Tracer tracer) {
+ return new HttpResponseInjectingTraceFilter(tracer, customHttpServletResponseSpanInjector());
}
In order to customize the polling mechanism you can create a bean of PollerMetadata type
-with name equal to StreamSpanReporter.POLLER. Here you can find an example of such a configuration.
@Configuration
-public static class CustomPollerConfiguration {
-
- @Bean(name = StreamSpanReporter.POLLER)
- PollerMetadata customPoller() {
- PollerMetadata poller = new PollerMetadata();
- poller.setMaxMessagesPerPoll(500);
- poller.setTrigger(new PeriodicTrigger(5000L));
- return poller;
- }
-}
-You can provide the spring.sleuth.integration.patterns pattern to explicitly
+
Since 1.0.4 you can provide the spring.sleuth.integration.patterns pattern to explicitly
provide the names of channels that you want to include for tracing. By default all channels
are included.
|
- Important
- |
-
-When using the Executor to build a Spring Integration IntegrationFlow remember to use the untraced version of the Executor.
-Decorating Spring Integration Executor Channel with TraceableExecutorService will cause the spans to be improperly closed.
- |
-