The GossipSubHistoryGossip global was unused, the config was defaulting HistoryGossip to the same GossipSubHistoryLength as HistoryLength
Make seenMessages cache TTL configurable without having to change the global. Eth2 and optimism both customize this differently, it should not only just be a global var.
Make PeerScoreParams not use the global TimeCacheDuration by adding a SeenMsgTTL field. It will default to the global value if the new field is not specified, so no breaking changes.
Update dependencies: the tests would not run in Go 1.18 because of the (indirect) quic dependency not yet supporting Go 1.18. Some other libp2p libs already updated. Not sure about coordination of releases, but doesn't look like these dependency updates break anything.
This PR fixes a few minor issues:
GossipSubHistoryGossip
global was unused, the config was defaultingHistoryGossip
to the sameGossipSubHistoryLength
asHistoryLength
seenMessages
cache TTL configurable without having to change the global. Eth2 and optimism both customize this differently, it should not only just be a global var.PeerScoreParams
not use the globalTimeCacheDuration
by adding a SeenMsgTTL field. It will default to the global value if the new field is not specified, so no breaking changes.