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

Make sure NettyDispatcher gets initialized #148

Merged
merged 2 commits into from
Dec 11, 2020
Merged

Conversation

tspring
Copy link
Contributor

@tspring tspring commented Dec 10, 2020

When testing the spring-webflux-5.3.1 changes, @jack-berg and I found that the initial Transaction created by Netty-4.0.8 instrumentation was never getting created. The issue is that AbstractServerBootstrap isn't always used, consequently never triggering the (re)instrumentation of NettyDispatcher::channelRead , which is the Transaction start poing

Copy link
Contributor

@jack-berg jack-berg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've tested this and it works.

@@ -26,12 +27,14 @@
public class NettyDispatcher {

private static volatile NettyDispatcher instance = null;
public static volatile AtomicBoolean instrumented = new AtomicBoolean(false);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's make this final.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, good call 👍

@tspring tspring merged commit 6fe104b into main Dec 11, 2020
@tspring tspring deleted the netty_dispatcher_init_fix branch December 11, 2020 23:18
jasonjkeller pushed a commit that referenced this pull request Jun 4, 2024
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

Successfully merging this pull request may close these issues.

2 participants