Split socket handling out of CConnman #30694

issue vasild openend this issue on August 22, 2024
  1. vasild commented at 9:53 am on August 22, 2024: contributor

    Please describe the feature you’d like to see added.

    Split CConnman in two pieces:

    • protocol agnostic low level socket and connection handler and
    • bitcoin-p2p protocol specific handler.

    This way the first part can be reused for Stratum V2 and for libevent-less RPC/HTTP server.

    Doing Stratum V2 and removing libevent from RPC requires duplicating some of the code from CConnman - binding and listening and the send/recv io loop.

    Describe the solution you’d like

    Split CConnman in such a way that the code can be reused.

    Describe any alternatives you’ve considered

    Duplicate code.

  2. vasild added the label Feature on Aug 22, 2024
  3. vasild commented at 9:55 am on August 22, 2024: contributor

    I am looking into doing this.

    cc @Sjors, @pinheadmz

  4. pinheadmz commented at 10:17 am on August 22, 2024: member

    I am looking into doing this.

    Wow thanks! My HTTP branch is almost done but is very messy. You can see me copy/paste/edit socket handling in

    https://github.com/pinheadmz/bitcoin/blob/http-netbase/src/http.cpp GenerateEventsPerSock() HandleConnections() AcceptConnections() etc…

  5. vasild commented at 7:58 am on September 27, 2024: contributor
    Done in #30988.

github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2024-12-21 12:12 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me