Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Dec 04 22:43
    dimi-nk commented #1753
  • Dec 04 22:39
    spring-issuemaster labeled #1795
  • Dec 04 22:37
    dimi-nk opened #1795
  • Dec 04 17:26
    OlegDokuka commented #1789
  • Dec 04 17:13
    marcingrzejszczak commented #1748
  • Dec 04 17:12
    marcingrzejszczak commented #1748
  • Dec 04 17:10
    marcingrzejszczak commented #1748
  • Dec 04 15:39
    spring-issuemaster labeled #1794
  • Dec 04 15:38
    jacekmg commented #1748
  • Dec 04 15:36
    marcingrzejszczak opened #1794
  • Dec 04 13:15
    marcingrzejszczak commented #1748
  • Dec 04 13:14
    marcingrzejszczak commented #1748
  • Dec 04 13:13
    marcingrzejszczak commented #1748
  • Dec 04 13:12
    marcingrzejszczak commented #1748
  • Dec 04 13:11
    marcingrzejszczak closed #1748
  • Dec 04 13:11
    marcingrzejszczak commented #1748
  • Dec 04 11:09
    marcingrzejszczak closed #1789
  • Dec 04 11:09

    marcingrzejszczak on master

    Guarding context retreval; fixe… Merge branch '2.2.x' (compare)

  • Dec 04 10:48
    CircleCI failed: spring-cloud build (#6535) in https://github.com/spring-cloud/spring-cloud-sleuth
    • Guarding context retreval; fixes gh-1789
      (68497e0c516c57fe9b7474213a71f23873257526 by Marcin Grzejszczak)
  • Dec 04 10:46

    marcingrzejszczak on 2.2.x

    Guarding context retreval; fixe… (compare)

Marcin Grzejszczak
@marcingrzejszczak
do you want to file a PR to the docs (master branch would be enough I guess)

btw add


        <dependency>
            <groupId>org.springframework.cloud</groupId>
            <artifactId>spring-cloud-sleuth-zipkin</artifactId>
        </dependency>

and it works fine

Fizii Q
@qfizii_gitlab
parser is now called but the added header is not seen by the client.
I suspect it's because spring message converter has already committed the response by the time servlet filter is called?
Marcin Grzejszczak
@marcingrzejszczak
interesting... let me check (BTW really thanks for checking all of this out - there's a lot of changes for Sleuth 3.0.0. BTW this is not a new feature but I've finally documented it properly)
Fizii Q
@qfizii_gitlab

If I choose W3C propagation type, each extra bagge field is sent twice. once in "baggage" header and once on its own.

baggage: country-code1=A,country-code2=B
country-code1: A
country-code2: B

is there a way to customize what sent in baggage header and what's sent on its own?

Marcin Grzejszczak
@marcingrzejszczak
yeah so what you can do is set spring.sleuth.otel.propagation.sleuth-baggage.enabled=false that way you'll have only the w3c ones
you're using OTel or Brave?
aman0008
@aman0008
Hi, i have 2 microservices. One is with spring boot and other is with dropwizard framework. I have successfully integrated sleuth with the spring boot service (It is edge service). But unable to get the tracing id and span id in my dropwizard service. Need help how to solve this issue.
Marcin Grzejszczak
@marcingrzejszczak
you have provided no meaningful information to help you out
no sleuth version info, no boot version, you didn't telll us what you did
nothing
aman0008
@aman0008

@marcingrzejszczak : Here are the details:

Application A (Spring boot Application (2.2.5.RELASE), JAVA 11)

pom.xml:

<dependency>
    <groupId>org.springframework.cloud</groupId>
    <artifactId>spring-cloud-starter-sleuth</artifactId>
</dependency>

I can see the tracing id and span id in my logs.

Application A makes and http call to Application B

Application B (Dropwizard framework, JAVA 8)

pom.xml:

<dependency>
    <groupId>org.springframework.cloud</groupId>
    <artifactId>spring-cloud-starter-sleuth</artifactId>
</dependency>

Unable to see the tracing id and span id in the logs

Let me know if more information is required.

Marcin Grzejszczak
@marcingrzejszczak
Yeah, application B doesn't use Spring so it won't work
Fizii Q
@qfizii_gitlab

spring.sleuth.otel.propagation.sleuth-baggage.enabled=false that way you'll have only the w3c ones

I am using brave. I tried setting these two props without success:

spring.sleuth.brave.propagation.sleuth-baggage.enabled=false
spring.sleuth.zipkin.propagation.sleuth-baggage.enabled=false
Marcin Grzejszczak
@marcingrzejszczak
Hmm I'll need a sample 😬
Anders Clausen
@AndersClausen
Hi @marcingrzejszczak . I was just reading this issue spring-cloud/spring-cloud-sleuth#707 and was wondering if it's completely dead in the water? Is there no way for me to send Sleuth tracing to Datadog (as far as you're aware)? We currently can't include the DD agent into our docker image because we're using spring boot maven plugin to create it (wish the builder from the Paketo buildpack would have a setting for it).
Marcin Grzejszczak
@marcingrzejszczak
Hi. There are ways to do it. you could register your own span handler bean that would take a mutablespan and upload it to dd (of course you'd have to take care of queueing those spans and sending them in batches I guess). What's the dd expected format?
With 3.0.0-m5 you can use opentelemetry with sleuth and dd understands that (https://github.com/flachnetz/dd-zipkin-proxy)
Marcin Grzejszczak
@marcingrzejszczak
wrong link
so regarding the 2 projects I mentioned - they would allow you to translate zipkin spans to datadog
Anders Clausen
@AndersClausen
Thanks for your very thorough answer @marcingrzejszczak - it's much appreciated
Fizii Q
@qfizii_gitlab
Fizii Q
@qfizii_gitlab
that's with brave.
trying with otel, it does work
Fizii Q
@qfizii_gitlab
with otel, setting or not setting spring.sleuth.baggage.remote-fieldshas no effect. baggage fields are always propagated:
spring.sleuth.baggage.remote-fields=my-header,my-header2 
baggage: my-header3=new-value3,my-header2=new-value2;propagation=unlimited,my-header=new-value;propagation=unlimited

#spring.sleuth.baggage.remote-fields=my-header,my-header2 
baggage: my-header=new-value,my-header3=new-value3,my-header2=new-value2
Marcin Grzejszczak
@marcingrzejszczak

@qfizii_gitlab can you file 1 issue please with not being able to disable baggage propagation for brave?

As for the second one the spring.sleuth.baggage.remote-fields will be applicable only for the Sleuth based way of propagating baggage - that means where baggage name, value = header key,value

Fizii Q
@qfizii_gitlab
where is propagation=unlimited coming from? it's not in W3C spec?
Marcin Grzejszczak
@marcingrzejszczak
no - it's a magic string :shrug:
I had a discussion about this with the OTel folks
you can pass arbitrary stuff there
initially in the otel implementation they passed propagation=unlimited from an enum, then they converted it to a string and then they said that it was just an example of how you could pass baggage metadata
so in general it's coming from Sleuth
Anders Clausen
@AndersClausen

@qfizii_gitlab thanks for the example above but I haven't had much luck so far. First of all, I couldn't get neither of the two open source projects to work and I'm unable to get the OpenTelemetry to work as well.
If I have a spring boot service with a REST endpoint (RouterFunction style) that makes a call out to Elasticsearch and then returns a response, that should generate me some tracing out-of-the-box right? As per the documentation, I have added the following two dependencies to my POM file:

        <dependency>
            <groupId>org.springframework.cloud</groupId>
            <artifactId>spring-cloud-starter-sleuth</artifactId>
        </dependency>
        <dependency>
            <groupId>org.springframework.cloud</groupId>
            <artifactId>spring-cloud-starter-sleuth-otel</artifactId>
        </dependency>

However, I'm still getting this error:

{
  "instant": {
    "epochSecond": 1606056361,
    "nanoOfSecond": 931753800
  },
  "thread": "main",
  "level": "ERROR",
  "loggerName": "org.springframework.boot.diagnostics.LoggingFailureAnalysisReporter",
  "message": "\r\n\r\n***************************\r\nAPPLICATION FAILED TO START\r\n***************************\r\n\r\nDescription:\r\n\r\nParameter 1 of method baggageTextMapPropagator in org.springframework.cloud.sleuth.otel.propagation.TraceOtelPropagationAutoConfiguration$BaggagePropagatorConfiguration required a single bean, but 2 were found:\r\n\t- braveTracer: defined by method 'braveTracer' in class path resource [org/springframework/cloud/sleuth/brave/bridge/TraceBraveBridgeAutoConfiguation.class]\r\n\t- otelTracerBridge: defined by method 'otelTracerBridge' in class path resource [org/springframework/cloud/sleuth/otel/bridge/TraceOtelBridgeAutoConfiguation.class]\r\n\r\n\r\nAction:\r\n\r\nConsider marking one of the beans as @Primary, updating the consumer to accept multiple beans, or using @Qualifier to identify the bean that should be consumed\r\n",
  "endOfBatch": false,
  "loggerFqcn": "org.apache.commons.logging.LogAdapter$Log4jLog",
  "threadId": 1,
  "threadPriority": 5
}

I've also got this property turned on for W3C

spring:
  sleuth:
    http:
      enabled: true
    web:
      enabled: true
      webclient:
        enabled: true
    reactor:
      enabled: true
    propagation:
      type: w3c

Do you know what I'm doing wrong or maybe @marcingrzejszczak can tell me? How do I disable brave now that I'm using otel? I know it's still in milestone state but are there any samples I can have a look at?
I'm using spring boot 2.4.0 and spring cloud 2020.0.0-SNAPSHOT
Lots of questions, I know :-( Thanks for your help

Marcin Grzejszczak
@marcingrzejszczak
This is wrong. You use either starter sleuth or starter otrl
Marcin Grzejszczak
@marcingrzejszczak
You'd don't need to explicitly set those to true since they are set to true out of the box
Anders Clausen
@AndersClausen
OK thanks @marcingrzejszczak but I did try and remove the starter sleuth but then it didn't recognise the spring.sleuth.propagation.type property. Having said that, I might have had a dodgy .M2 directory so I'll try again. Thanks for replying though
Anders Clausen
@AndersClausen
With regards to above statement - it turned out to be a false/positive with IntelliJ
Anders Clausen
@AndersClausen
I'm connecting fine to Datadog after deployment, however I still don't see any tracing data in APM. I guess it's because io.opentelemetry doesn't have an exporter for Datadog. Do you think that's the correct conclusion @marcingrzejszczak ? I know you pointed me to the Datadog blog post the other day - the one that describes them embracing OpenTelemetry but I'm not sure they have actually worked on that since
Marcin Grzejszczak
@marcingrzejszczak
yes that's the reason
rubenca01
@rubenca01
Hi guys, I am struggling configuring sleuth on a Grails application in order to publish traceid on a GrayLog services.
Avinash Shelke
@avinash9shelke
Hi team ,
Once I set it the property sleuth.scheduled.enabled=false feign calls creating new traceid
Marcin Grzejszczak
@marcingrzejszczak
are you using the latest version?
Avinash Shelke
@avinash9shelke
@marcingrzejszczak I am using 2.2.4.RELEASE also try with 2.2.5.RELEASE same issue occurred
Marcin Grzejszczak
@marcingrzejszczak
You'd have to create a sample so thaat I can check it out
Avinash Shelke
@avinash9shelke
@marcingrzejszczak yah sure