Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
R
re6stnet
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
5
Merge Requests
5
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
re6stnet
Commits
937856a8
Commit
937856a8
authored
Jun 07, 2019
by
Killian Lufau
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Change bootstrap condition
parent
3af8555f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
6 deletions
+4
-6
re6st/tunnel.py
re6st/tunnel.py
+4
-6
No files found.
re6st/tunnel.py
View file @
937856a8
...
...
@@ -889,11 +889,11 @@ class TunnelManager(BaseTunnelManager):
if
route_dumped
:
logging
.
debug
(
'Analyze routes ...'
)
neighbours
=
self
.
ctl
.
neighbours
# Collect all nodes known by Babel
# Collect all
reachable
nodes known by Babel
peers
=
set
(
prefix
for
neigh_routes
in
neighbours
.
itervalues
()
for
prefix
in
neigh_routes
[
1
]
if
prefix
)
for
prefix
,
route
in
neigh_routes
[
1
].
iteritems
()
if
prefix
and
route
.
metric
<
0xffff
)
# Keep only distant peers.
distant_peers
[:]
=
peers
.
difference
(
neighbours
)
distant_peers
.
sort
(
key
=
self
.
_newTunnelScore
)
...
...
@@ -904,9 +904,7 @@ class TunnelManager(BaseTunnelManager):
# Faster recovery of registry node: use cache instead
# of waiting that another node tries to connect to it.
distant_peers
=
None
elif
(
registry
in
peers
or
registry
in
self
.
_connection_dict
or
registry
in
self
.
_served
):
elif
registry
in
peers
:
self
.
_disconnected
=
0
# Be ready to receive any message from the registry.
self
.
sendto
(
registry
,
None
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment