-
Notifications
You must be signed in to change notification settings - Fork 596
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
Fix bugs in Redisson plugin #693
Conversation
...-plugin/src/main/java/org/apache/skywalking/apm/plugin/redisson/v3/RedissonPluginConfig.java
Outdated
Show resolved
Hide resolved
Note, the plugin tests fail about this plugin, please recheck. |
Meanwhile, with your ASF ID created, you should be able to join ASF org(GitHub), and make the CI running automatically without my manual approval. |
OK |
...main/java/org/apache/skywalking/apm/plugin/redisson/v3/RedisConnectionMethodInterceptor.java
Outdated
Show resolved
Hide resolved
} else if (allArguments[0] instanceof CommandData) { | ||
CommandData commandData = (CommandData) allArguments[0]; | ||
command = commandData.getCommand().getName(); | ||
operationName = operationName + command; | ||
arguments = commandData.getParams(); | ||
if ("PING".equals(command) && !RedissonPluginConfig.Plugin.Redisson.SHOW_PING_COMMAND) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@wu-sheng This change will lead to a problem that the plugin cannot find an active span to close after "Ping" execution. Skywalking would throw a NullPointerException. Maybe it needs a flag to duel this situation.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you want to write that PR? I think this is easy. You just need to add if ("PING".equals(command) && !RedissonPluginConfig.Plugin.Redisson.SHOW_PING_COMMAND) {
check in the #afterMethod
and avoid ContextManager.stopSpan();
in this case.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@CzyerChen I think this is definitely going to happen.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This issue has been resolved by @Ricehomesky from our team in our private code several days ago. I suppose he can raise a PR very soon.
Fix bugs in Redisson plugin
Fix NPE in Redisson tracing since 3.20.0, because ServiceManager.Config replaces Config in MasterSlaveConnectionManager.
Add params: skywalking.plugin.redisson.show_batch_commands=true(default false), to show batch_execute details
Add params: skywalking.plugin.redisson.ping_ignored=true(default true), to avoid ping tracing cost, the filtering configuration of PING since 3.13.6 that default ping per 30s
connect to redis in Master-Slave mode
peer before:
peer now:
CHANGES
log.