feat(p2p): add address info to peer event reporting #19716#2371
feat(p2p): add address info to peer event reporting #19716#2371gzliudan wants to merge 1 commit into
Conversation
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Pull request overview
This PR enhances p2p peer event reporting by including connection endpoint information (local/remote addresses) in PeerEvent emissions, improving observability for peer lifecycle and message traffic events.
Changes:
- Extend
p2p.PeerEventwithLocalAddressandRemoteAddressfields (JSONlocal/remote). - Populate local/remote addresses for peer add/drop events in
p2p/server.go. - Populate local/remote addresses for per-message send/receive events via
msgEventer.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
p2p/server.go |
Adds local/remote endpoint strings to peer add/drop events. |
p2p/peer.go |
Passes connection address info into the message event wrapper during protocol startup. |
p2p/message.go |
Extends message send/recv peer events to include local/remote addresses and updates msgEventer to carry them. |
Proposed changes
Ref: ethereum#19716
Types of changes
What types of changes does your code introduce to XDC network?
Put an
✅in the boxes that applyImpacted Components
Which parts of the codebase does this PR touch?
Put an
✅in the boxes that applyChecklist
Put an
✅in the boxes once you have confirmed below actions (or provide reasons on not doing so) that