Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Span is not linked with spring cloud gateway #46

Open
nitin-vavdiya opened this issue May 3, 2019 · 12 comments
Open

Span is not linked with spring cloud gateway #46

nitin-vavdiya opened this issue May 3, 2019 · 12 comments

Comments

@nitin-vavdiya
Copy link

I am working on microservice architecture

User-------->Spring cloud gateway------------->Service A-------------->Service B

In Jaeger, It shows 2 different spans, one in gateway and other is service A --> Service B
But it should be a single span ie. gateway-----> Service A----->Service B

API gateway is developed using spring cloud gateway
Service A is developed using spring boot
Service B is developed using spring boot

Version info for all 3 application:

compile group: 'commons-lang', name: 'commons-lang', version: '2.6' springBootVersion=2.1.4.RELEASE springDMPVersion=1.0.9.RELEASE springPlatformBomVersion=Cairo-SR8 springCloudVersion=Greenwich.SR1

@geoand
Copy link
Collaborator

geoand commented May 3, 2019

I haven't really used Spring Cloud Gateway, but here is something that might help - can you try setting:

opentracing.jaeger.enable-b3-propagation = true

in Service A and Service B please and let us know what happens?

@nitin-vavdiya
Copy link
Author

nitin-vavdiya commented May 3, 2019

@geoand
After applying this, the link between Service A and Service B is broken, Now it's showing three different spans for each application

@ghost
Copy link

ghost commented May 6, 2019

@3vild03r
Can you please update your comment, it is not readable

@geoand
Copy link
Collaborator

geoand commented May 6, 2019

@nitinvavdiya Unfortunately I don't have much time to look into this now (not being familiar with Spring Cloud Gateway does not help :) ). Hopefully I will soon.

@neatlife
Copy link

@nitinvavdiya I fixed it, see pr: opentracing-contrib/java-spring-cloud#233

@ghost
Copy link

ghost commented Jul 22, 2019

@neatlife
In which version you fixed it?

@astrisk
Copy link

astrisk commented Aug 30, 2019

@neatlife I test the code,not work.

@nicorbes
Copy link

nicorbes commented Aug 30, 2019

Hi guys, I run into the same issue... any ideas?

We created a GlobalFilter go generate the span and pass the traceID to the next service. And it is working... but the problem is that we are creating the local spring cloud gateway span with the incoming request instead of the outgoing... that's why this solution is no good.

Does some of you how to interact with the underneath HttpClientConnect object?

I left the code explanation and also de question on stackoverglow.

Thanks in advance!

@caorui31
Copy link

caorui31 commented Sep 18, 2019

@nitinvavdiya I fixed it, see pr: opentracing-contrib/java-spring-cloud#233

Hi @neatlife
Will you submit again? I see that the previous submission failed.

@HaojunRen
Copy link

I met this issue too, now any update?

@zhangxi123
Copy link

can anybody help

@AhHa45
Copy link

AhHa45 commented Mar 22, 2021

I have the exact same issue Spring Boot 2.3.1 "io.opentracing.contrib:opentracing-spring-jaeger-web-starter:3.3.1"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

9 participants