-
Notifications
You must be signed in to change notification settings - Fork 606
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 missing attributes in RedisCluster spans #2626
base: main
Are you sure you want to change the base?
Conversation
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.
Thanks for the PR, I think this is missing a test to check it's working :)
(cherry picked from commit c1f2cd6)
I've added the requested test Have to admit that mocking RedisCluster was a challenge. |
@a-cid please take a look at failing docker tests |
Fixed |
Co-authored-by: Emídio Neto <9735060+emdneto@users.noreply.github.com>
if hasattr(conn, "nodes_manager") and hasattr( | ||
conn.nodes_manager.default_node, "redis_connection" | ||
): | ||
conn = conn.nodes_manager.default_node.redis_connection |
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.
Can we not access connection_kwargs
directly from the NodeManager or is this a different set of kwargs?
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.
Apologies for the delay, I've been a bit busy with work.
The call to cleanup_kwargs removes host
and port
from the kwargs passed to the NodeManager, so we have to get them from the nodes.
Description
Modifies
_set_connection_attributes
to handleconn
being an instance ofredis.cluster.RedisCluster
.Fixes #2505
Type of change
How Has This Been Tested?
Does This PR Require a Core Repo Change?
Checklist:
See contributing.md for styleguide, changelog guidelines, and more.