by

Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • 16:51
    CircleCI success: spring-cloud build (#6390) in https://github.com/spring-cloud/spring-cloud-sleuth
    • Moved properties around, added modules, added otel module
      (c5d86a0529befc56281dfc19b0a6954d606e1fe8 by Marcin Grzejszczak)
  • 16:42

    marcingrzejszczak on otel_2

    Moved properties around, added … (compare)

  • 10:10
    spring-issuemaster labeled #1742
  • 10:08
    rstoyanchev opened #1742
  • 09:36
    rstoyanchev commented #1184
  • 09:19
    rstoyanchev commented #1184
  • 09:19
    rstoyanchev commented #1184
  • 09:12
    rstoyanchev commented #1732
  • Sep 28 21:25
    spring-issuemaster labeled #1741
  • Sep 28 21:23
    voipp opened #1741
  • Sep 28 11:41
    mikhailsoparin commented #1583
  • Sep 28 11:16
    CircleCI failed: spring-cloud build (#6389) in https://github.com/spring-cloud/spring-cloud-sleuth
  • Sep 28 11:10

    marcingrzejszczak on otel_2

    Tests are passing (compare)

  • Sep 28 11:10
    marcingrzejszczak closed #1734
  • Sep 28 08:33
    violetagg commented #1690
  • Sep 27 11:23
    kewkew1026 commented #1740
  • Sep 27 08:50
    spring-issuemaster labeled #1740
  • Sep 27 08:47
    kewkew1026 opened #1740
  • Sep 25 15:47
    CircleCI failed: spring-cloud build (#6388) in https://github.com/spring-cloud/spring-cloud-sleuth
  • Sep 25 15:36

    marcingrzejszczak on otel_2

    WIP on tests (compare)

Adrian Cole
@adriancole
webclient is already instrumented, so what you are asking for is the method that called webclient?
if you are using a interface pattern like feign, this will happen
raw webclient no
not that I know of anyway
MelvinStephen
@MelvinStephen
we have of service method execution between the rest controller and webclient call and also after the webclient call we have service methods executing some logic. we would want to track the time taken bet each of these methods. so that we can find out where time is being spent. we are looking to see if we have sleuth and zipping solve this for us
Adrian Cole
@adriancole
@MelvinStephen it sounds like you are looking for more a profiler based thing?
is it that you are unable to determine the cause of your webclient calls?
given that the rest controller already has java invocation details..
Marcin Grzejszczak
@marcingrzejszczak
You could create an aspect yourself that wraps all public methods although it sounds brutal. If tog beg even better granularity then you should use a profiler
*if you need...
MelvinStephen
@MelvinStephen
Can you suggest me a profiler? I will look at it
Adrian Cole
@adriancole
@MelvinStephen this isn't like a sleuth endorsement, just personal
skywalking has a neat way to automatically profile things now
the jist is that this hooks at a lower level than what we currently do in sleuth (java agent)
what they are doing here isn't impossible in sleuth, just we've not explored it. elastic apm has similar tech
there are some pitfalls, when translating I tried to elaborate some, but it isnt complete
in general you may or may not need this
for example, if you have web clients that aren't annotation driven, sure you won't know where they came from
but you would know the last position they came from (Ex the webmvc controller)
and also annotation driven is still an option
what @marcingrzejszczak said is true also, that it would get hairy to implement your own profiler.. which is why I asked if it is purely important
Adrian Cole
@adriancole
ex many use log correlation and while there are flaws in that, often the method or class are evidednt in logging format
anyway these are some good context for you, so best to process that and think about it
Invoker-liu
@Invoker-liu
@adriancole thank you,After look over docs,it means the client must be a bean,that's sad,i will try other
Adrian Cole
@adriancole
@Invoker-liu just trying to be honest with you
I worked on the web client stuff recently reactor web etc
definitely try 2.2.3 snapshot first to withhold judgement but it might be the same. if there's a trace break, just open an issue, it can be solved or at least explained.
MelvinStephen
@MelvinStephen
sure, let me try exploring apache skywalking
Adrian Cole
@adriancole
cool iirc you can collaborate sleuth and skywalking as skywalking also can accept zipkin format
they are smart and earnest, like us I hope :D
Invoker-liu
@Invoker-liu
@adriancole Thanks!I will consider adding issue to github
Adrian Cole
@adriancole
:thumbsup:
Ghenadii Batalski
@ghenadiibatalski
hi, could one give me please a hint about reactor kafka instrumentation
Marcin Grzejszczak
@marcingrzejszczak
It doesn't work out of the box?
Ghenadii Batalski
@ghenadiibatalski
@marcingrzejszczak sorry, was afk, i don't know how it should work out of the box. Is there any example or even a (detailed) docu ? For webflux and webclient it does work, but not the reactive kafka. The way i'm creating a sender/receiver could be a problem, if it should work
Ghenadii Batalski
@ghenadiibatalski

@marcingrzejszczak this is my sample code

       // sender
        sender = KafkaSender.create(senderOptions);
        processor = DirectProcessor.<Tuple2<String,String>>create().serialize();
        sink = processor.sink();
        sender.send(processor.map(objects ->  SenderRecord.create(new ProducerRecord<>("topic1", objects.getT1(), objects.getT2()),objects.getT2())))
                .doOnNext(senderResult -> log.info(senderResult.correlationMetadata()))
                .subscribe();
       // receiver
        receiver = KafkaReceiver.create(receiverOptions);
        receiver
                .receive()
                .doOnNext(receiverRecord -> log.info("key: {}, value: {}", receiverRecord.key(), stringStringReceiverRecord.value()))
                .subscribe();

send on rest call

    sink.next(Tuples.of("key", ""+System.nanoTime()));

log:

   2020-05-29 00:07:43.063  INFO [demo,,,] 31028 --- [       single-1] com.example.demo.DemoApplication         : 88843267100400
   2020-05-29 00:07:43.064  INFO [demo,,,] 31028 --- [     parallel-2] com.example.demo.DemoApplication         : key: key, value: 88843267100400
Adrian Cole
@adriancole
@ghenadiibatalski maybe thumbsup this or comment with your example for now? reactor/reactor-kafka#128
Marcin Grzejszczak
@marcingrzejszczak
I'm not an expert with reactor kafka but shouldn't you use beans instead of static methods?
Ucky.Kit
@uckyk
image.png
Adrian Cole
@adriancole
@uckyk looks like context leak (same trace ID stuck on a thread)
so depending on what's used and what is in the classpath might explain
Ucky.Kit
@uckyk
image.png
Adrian Cole
@adriancole
ok that is sadly a dead end version
Ucky.Kit
@uckyk
Because the project is relatively old, the introduced version of spring cloud is relatively low
Adrian Cole
@adriancole
even 2.0 2.1 aren't maintained anymore
this version used a way for "scoping" which was not try/finally in nature
and so had a higher chance of leaks vs the 2.x line which use brave's CurrentTraceContext api
Ucky.Kit
@uckyk
I have observed that the 2. X version basically uses the wave related POM
Adrian Cole
@adriancole
yeah the custom tracing api from 1.x is no longer around