Comments (1)
Hey @bijukunjummen , sorry for the very late response on this.
It's become increasingly clear that we cannot rely on WebClient
threading behaviors being consistent, especially between versions of Spring - even supposedly non-breaking version updates of Spring. You can see I just had to drop support for some of the minimal auto-magic tracing propagation wingtips was already attempting to do, due to a breaking change with how spring handles their threading: see this comment in the javadocs.
☝️ is important for your example as well, given that your example does not use webClient.attribute(TracingState.class.getName(), TracingState.getCurrentThreadTracingState())
to propagate the tracing state. Please read the linked javadoc comment carefully, and start using the webClient.attribute(...)
mechanism to do the initial tracing state propagation, otherwise you'll upgrade spring someday and all your WebClient calls will fail to do distributed tracing correctly!
There may be some very complex way to auto-magic the tracing state onto threads as WebClient
hops from thread to thread, but the effort required would undoubtedly be very large and I'd be skeptical about its fragility.
My recommendation on your specific question around map
and flatMap
would be to use the wingtips-java8 features (see examples here) to wrap your map
and flatMap
functions to ensure the proper tracing state is attached when those functions execute. Same idea as what we're dong here in the SB2 webflux sample app.
from wingtips.
Related Issues (17)
- Implement an interceptor for Apache's HttpAsyncClient
- withTracing() appears to never call `run` on Runnable HOT 1
- ConcurrentModificationException in SpanParser
- wingtips-zipkin: NumberFormatException in WingtipsToZipkinSpanConverterDefaultImpl HOT 14
- Switch to hex-encoded IDs for full B3 compatibility with Zipkin HOT 1
- Add support for Zipkin's ERROR annotation HOT 8
- OpenTracing support
- Add annotations/tags/baggage support to Spans HOT 4
- Change RequestTracingFilter to return the trace ID as a X-Wingtips-RequestId header rather than X-B3-TraceId
- Allow full control over log output format
- Support optional 128-bit trace ID generation.
- Merge the servlet filter into one that works in both Servlet 2.x and 3.x evironments HOT 2
- Span should implement Closeable instead of AutoCloseable. HOT 2
- Any plans to update this to zipkin v2 api? HOT 6
- implement "b3 single" header format
- Complete zipkin compatibility HOT 18
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from wingtips.