go-algorand
go-algorand copied to clipboard
p2p: hybrid node net identity for connection deduplication
Summary
- Refactored net identity scheme constructors to allow hybrid net to create p2pNet and wsNet with predefined identity trackers and schema.
- Allowed multiple dedup names in identity tracker.
- Setting
EnableP2PHybridMode
also requiresPublicAddress
to be set on nodes listeningNetAddress
orP2PNetAddress
- Added hybrid p2p scenarios to
netdeploy
- Removed
gossipSubPeer
type because of type cast in hybrid mode causing panic (see in comments) - Fixed possible letter case mismatch of
PublicAddress
from config with netAddr fetched from DNS.
Test Plan
Added new unit tests and run cluster tests.
Pulled TODOs from https://github.com/algorand/go-algorand/pull/5939
- [x] cluster performance tests for hybrid mode
Validated deduplication in logs, found and fixed PublicAddress vs DNS netAddr letter case issue.
scenario1s half: 4R+4N+4NPN results:
hybrid=p2p (all nodes p2p, some hybrid): 6244.04 TPS hybrid=ws (all nodes ws, some hybrid): 6225.84 TPS hybrid=no (all nodes p2p): 6244.78 TPS
- [ ] connection/traffic limits are aggregated for both ws and p2p nets in hybrid mode