Based on #30315 and #30205, parent PR #29432.
This PR introduces Sv2Connman
which is somewhat similar to CConnman
. It uses the Sv2Transport
introduced in #30315 to enable incoming connections from other Stratum v2 roles.
It’s main target user is the Template Provider role introduced in #29432.
There may be other Stratum v2 roles we want to support in the future.
A remaining issue is that the code in ThreadSv2Handler
reuses a lot of code from CConnman::SocketHandlerConnected
. I’d like to find a way to extract this common functionality and put it somewhere else.
TODO:
- use mock sockets from #30205
- make
CConnman::SocketHandlerConnected
(partially) reusable