plugeth/p2p/discover
Felix Lange 9afc6816d2
common/lru: add generic LRU implementation (#26162)
It seems there is no fully typed library implementation of an LRU cache.
So I wrote one. Method names are the same as github.com/hashicorp/golang-lru,
and the new type can be used as a drop-in replacement.

Two reasons to do this:

- It's much easier to understand what a cache is for when the types are right there.
- Performance: the new implementation is slightly faster and performs zero memory
   allocations in Add when the cache is at capacity. Overall, memory usage of the cache
   is much reduced because keys are values are no longer wrapped in interface.
2022-11-14 15:41:56 +01:00
..
v4wire all: fix docstrings 2022-10-04 09:18:02 +02:00
v5wire common/lru: add generic LRU implementation (#26162) 2022-11-14 15:41:56 +01:00
common.go p2p: remove term "whitelist" (#23295) 2021-07-29 17:50:18 +02:00
lookup.go p2p: use errors.Is for error comparison (#24882) 2022-06-07 17:27:21 +02:00
node.go p2p/discover: implement v5.1 wire protocol (#21647) 2020-10-14 12:28:17 +02:00
ntp.go p2p/discover: fix typos in comments (#25272) 2022-07-10 10:15:54 +02:00
table_test.go p2p/discover: avoid dropping unverified nodes when table is almost empty (#21396) 2020-08-24 14:42:39 +02:00
table_util_test.go p2p/discover: fix typos in comments (#25272) 2022-07-10 10:15:54 +02:00
table.go p2p/discover: fix typo in comments (#21554) 2020-09-11 20:35:38 +02:00
v4_lookup_test.go p2p/discover: implement v5.1 wire protocol (#21647) 2020-10-14 12:28:17 +02:00
v4_udp_test.go p2p: add channel buffers to avoid goroutine leaks in tests (#24929) 2022-09-23 10:51:12 +02:00
v4_udp.go all: fix some typos (#25551) 2022-08-19 09:00:21 +03:00
v5_udp_test.go p2p/discover: improve discv5 NODES response packing (#26033) 2022-11-07 19:19:02 +01:00
v5_udp.go p2p/discover: improve discv5 NODES response packing (#26033) 2022-11-07 19:19:02 +01:00