Skip to content

Conversation

@turuslan
Copy link
Contributor

  • ping protocol
  • identify protocol
  • fix quic incoming connection address
  • some changes from gossip #6

@turuslan turuslan requested a review from kamilsa August 26, 2025 07:17
@kamilsa kamilsa requested a review from Copilot September 11, 2025 11:01
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR implements ping and identify protocols for libp2p, along with a fix for QUIC connection address handling. It adds two core libp2p protocols that enable peer connectivity testing and peer information exchange.

  • Implements ping protocol for peer connectivity testing with configurable timeout and interval
  • Implements identify protocol for exchanging peer information including addresses and supported protocols
  • Fixes QUIC incoming connection address resolution to use actual peer endpoint

Reviewed Changes

Copilot reviewed 18 out of 18 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
src/transport/quic/engine.cpp Fixes QUIC connection to use actual peer socket address instead of remote address from operation
src/protocol/ping.cpp Implements ping protocol with echo functionality and periodic ping operations
src/protocol/identify/identify.proto Defines protobuf schema for identify protocol messages
src/protocol/identify/identify.cpp Implements identify protocol for peer information exchange
src/protocol/identify/CMakeLists.txt Build configuration for identify protocol
src/protocol/CMakeLists.txt Build configuration for ping protocol
src/host/basic_host.cpp Changes constructor parameters from unique_ptr to shared_ptr and adds new methods
src/CMakeLists.txt Links new protocol libraries
include/libp2p/protocol/ping.hpp Header for ping protocol implementation
include/libp2p/protocol/identify.hpp Header for identify protocol implementation
include/libp2p/peer/protocol.hpp Simplifies protocol name type definitions
include/libp2p/host/basic_host.hpp Updates method signatures for shared_ptr usage
include/libp2p/coro/yield.hpp Utility for coroutine thread switching
include/libp2p/common/weak_macro.hpp Macros for weak pointer handling
include/libp2p/common/protobuf.hpp Utilities for protobuf encoding/decoding
include/libp2p/basic/write_varint.hpp Utility for writing varint-prefixed messages
include/libp2p/basic/read_varint.hpp Utility for reading varint-prefixed messages
include/libp2p/basic/encode_varint.hpp Utility for varint encoding

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@turuslan turuslan force-pushed the feature/ping-identify branch from 64e6c38 to 68cb463 Compare September 12, 2025 09:57
@turuslan turuslan requested a review from kamilsa September 12, 2025 09:58
@turuslan turuslan merged commit f5d7e82 into main Sep 12, 2025
2 checks passed
@turuslan turuslan deleted the feature/ping-identify branch September 12, 2025 13:38
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.

3 participants