Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
N
neo
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
2
Merge Requests
2
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Jobs
Commits
Open sidebar
Kirill Smelkov
neo
Commits
99ac542c
Commit
99ac542c
authored
Nov 23, 2015
by
Julien Muchembled
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Do not send useless node information to bootstraping node
parent
cff279af
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
3 additions
and
6 deletions
+3
-6
neo/lib/bootstrap.py
neo/lib/bootstrap.py
+0
-3
neo/master/app.py
neo/master/app.py
+2
-2
neo/master/handlers/identification.py
neo/master/handlers/identification.py
+1
-1
No files found.
neo/lib/bootstrap.py
View file @
99ac542c
...
...
@@ -41,9 +41,6 @@ class BootstrapManager(EventHandler):
self
.
num_partitions
=
None
self
.
current
=
None
def
notifyNodeInformation
(
self
,
conn
,
node_list
):
pass
def
announcePrimary
(
self
,
conn
):
# We found the primary master early enough to be notified of election
# end. Lucky. Anyway, we must carry on with identification request, so
...
...
neo/master/app.py
View file @
99ac542c
...
...
@@ -221,7 +221,7 @@ class Application(BaseApplication):
self
.
primary
=
self
.
primary
is
None
break
def
broadcastNodesInformation
(
self
,
node_list
):
def
broadcastNodesInformation
(
self
,
node_list
,
exclude
=
None
):
"""
Broadcast changes for a set a nodes
Send only one packet per connection to reduce bandwidth
...
...
@@ -243,7 +243,7 @@ class Application(BaseApplication):
# send at most one non-empty notification packet per node
for
node
in
self
.
nm
.
getIdentifiedList
():
node_list
=
node_dict
.
get
(
node
.
getType
())
if
node_list
and
node
.
isRunning
():
if
node_list
and
node
.
isRunning
()
and
node
is
not
exclude
:
node
.
notify
(
Packets
.
NotifyNodeInformation
(
node_list
))
def
broadcastPartitionChanges
(
self
,
cell_list
):
...
...
neo/master/handlers/identification.py
View file @
99ac542c
...
...
@@ -72,7 +72,7 @@ class IdentificationHandler(MasterHandler):
node
.
setState
(
state
)
node
.
setConnection
(
conn
)
conn
.
setHandler
(
handler
)
app
.
broadcastNodesInformation
([
node
])
app
.
broadcastNodesInformation
([
node
]
,
node
)
return
uuid
class
SecondaryIdentificationHandler
(
MasterHandler
):
...
...
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