Commit Graph

10 Commits

Author SHA1 Message Date
Milos Gajdos
a72a2f717d
Prune stale nodes in the whole topology. 2019-09-16 19:22:55 +01:00
Milos Gajdos
323a72be34
Small refactoring; Split horizon loop break. 2019-09-13 18:46:24 +01:00
Milos Gajdos
b91c3147e7
Node API allows us to drop all network locks
Network locks are now needed only when accessing client map. node map
access is serialied with the node mutex.
2019-09-13 03:03:56 +01:00
Milos Gajdos
77c6c9781b
getProtoTopology has been replaced by PeersToProto
This helps us remove redundant code across node and handler
2019-09-13 03:03:56 +01:00
Milos Gajdos
fa4ff8921e
Removed redundant lock. Simplified proto topology 2019-09-13 03:03:56 +01:00
Milos Gajdos
d6be91e8af
Changed RPC methods. Changed Network interface.
* Nodes/Topology removed from public methods from Network interface
* Peers() returns max depth 3 topology
* handler.Topology rpc endpoint removed
* handler.Peers rpc endpoint accept "depth" param to return max depth peers
2019-09-13 03:03:56 +01:00
Milos Gajdos
588484c3bf
Fixed some races. Added more tests. 2019-09-13 03:03:56 +01:00
Milos Gajdos
35cf2a5739
Make topology test more generic 2019-09-13 03:03:55 +01:00
Milos Gajdos
2dfbe93d65
Added more node tests. Small refactoring of Netowkr and handler. 2019-09-13 03:03:55 +01:00
Milos Gajdos
16fcf1fbda
Nodes, Peers and Topology methods for node
Topology accepts an argument to define the depth of the topology
requested from the network. proto definitions have been modified
accordingly, too.
2019-09-13 03:03:55 +01:00