spring-cloud-sleuth
spring-cloud-sleuth copied to clipboard
Make Zipkin timeout configurable
Currently connecting to Zipkin has a hardcoded 1-second timeout, which for me isn't long enough. When I connect to a Zipkin server behind a VPN from my local PC on the other side of the world this times out.
The workaround that I did now was to create my own Reporter bean. This would have been much simpler if it was just a config property, like the message timeout.
I'll create a PR if the team thinks this is a good feature to add.
Makes sense, please file a pr :)
This hardcoded 1-second timeout means that there's a pre-check on the sender, and that check has a timeout of one second. If this check fails, it appears that only a WARN log will be printed. Is it necessary to specifically make this timeout configurable?
If you are using the default sender, which use RestTempalte. It looks like prior to version 3.1.0, RestTemplate had a hardcoded connect&read timeout of 500 milliseconds (You do need to create your own Reporter), but after 3.1.0 provides ZipkinRestTemplateProvider, you can inject your custom RestTemplate.
Please upgrade to Micrometer Tracing. Spring Cloud Sleuth is feature complete and out of OSS support.