Commit Graph

5 Commits

Author SHA1 Message Date
Jacek Sieka 2baa4c02a1
avoid allocation in `hash(ValidIpAddress)` (#433)
* avoid allocation in `hash(ValidIpAddress)`

While casually browsing the profiler output, to my great surprise I
found that an allocating string conversion function (gasp!) in the hash
function for ip addresses - this PR carefully excises this evil
construct from the codebase.

* bump nim version
2021-11-29 20:58:45 +01:00
kdeme e10ef19f81
Move push raises to top and add/update license info where needed 2021-04-28 16:20:05 +02:00
Kim De Mey be5e088b21
Move parsing of nat cli option out of setupAddress (#331)
* Move parsing of nat cli option out of setupAddress

* Change some proc to func
2021-03-05 21:23:54 +01:00
Kim De Mey 0700ec770f
Improve network address discovery / NAT setup (#323)
* Add search for best route and refactor setupNat to setupAddress

* Update setupAddress and make enr ports in discovery optional

* Add specific error log when no route is found
* Use bindIP if it is public
* Adjust some log levels
2021-03-02 17:13:29 +01:00
Kim De Mey b4c1391be9
Discv5 ip limits for routing table (#308)
* Add ip limits to routing table and routing table buckets

* Fix order of ip limit check and duplicate check for replacement

* Fix ip limit for node with updated ip in ENR

* Fix bug where address wouldn't update on ENR update

and update some comments

* Reuse some add/remove code in routing table

* Fix seen bug on ENR update in routing table

* Rework addNode to make sure to do address check always

and adjust some logs.

* More documentation on the ip limits in routing table [skip ci]
2020-11-26 18:20:15 +01:00