-
Notifications
You must be signed in to change notification settings - Fork 518
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(ioredis): set net.peer.name
attribute according to spec
#241
Conversation
Codecov Report
@@ Coverage Diff @@
## master #241 +/- ##
=======================================
Coverage 94.95% 94.95%
=======================================
Files 115 115
Lines 5990 5990
Branches 618 618
=======================================
Hits 5688 5688
Misses 302 302 |
Should we parse the host to see if it is an IP and if so set NET_PEER_IP instead? |
In my opinion it makes sense this way, because we populate the attribute from what the user configured, and not extracting IP address from the socket itself like the HTTP plugin is doing. |
What I meant is that a host set by the user can either be a name or an IP. If we choose one PEER NAME is good, but ideally we check if the host is an IP and if so we set pEER IP but if it's a name we set PEER NAME |
If you do choose to implement this check the following SO post might help. If not it's fine this lgtm since it's already an improvement |
In reality the spec should probably just have PEER HOST |
Which problem is this PR solving?
fixes #240
Short description of the changes
replace attribute
net.peer.host
withnet.peer.name
so it follows the specification Semantic conventions for database client calls