There is quite a bit of new functionality driven from the network management method implementations. For example, there has been no way to enumerate running channels, as that starts breaking the lock-free network design. When Core audits the channel set for diagnostics, it takes a lock of the entire network - all channels. We send a message to all channel subscribers and they write a response, and we collect the responses when they are all handled, or collect the first responder as the case may be.
So I generalized this approach to enumerate channels, to get their state and statistics, etc. I also added a broadcast to stop a channel, including the option to stop and drop a manual channel from retry. These are targetable by unresolved and resolved (for non-proxied IP addresses) address. I also added per-channel-per-p2p-message-type send and receive byte counters, and total send/receive byte counters for the process lifetime. These then report back to the caller and summarize as necessary once collected.
In order to avoid contention on lots of channels updated lots of atomics to obtain the process totals, I implemented a mechanism whereby the process totals are only updated when a channel stops, running channel totals are swept dynamically, and the two are reconciled by the caller to get the running totals. This is guarded by the set of running channel IDs being maintained at the point of channel drop, atomically with the total update. So the sweep can be subtracted from totals if double-counted. So a consistent snapshot in time with no locking, and the collection cost moved to the administrative caller.
(edited)