Open merlinrabens opened 7 years ago
That is a good idea. This way, the nstats script could implement the re-activation of temporarily 'out-of-order' peers properly. For TCP neighbors, IRI will have to protect itself against too frequently issued ping request, because otherwise the receiver thread pool could get exhausted.
Addendum: It would be good to have this neighbor ping restricted in terms of not allowing internet discovery of IRI nodes. This could be done for instance by exchanging a token on first connect.
It would be good to have a check, if a neighbor is up or not by means of telling if the IRI neighbor node is in ready state to mutually exchange txs or not. It should be not only a ping-like check, it should go beyond this because a host can be up, but IRI shutdowned, or a network rule could block IRI specific traffic.
This would help enormously in terms of reducing bad neighbors and could be leveraged heavily, e.g. by https://github.com/bluedigits/nstats