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
ff076765
Commit
ff076765
authored
Mar 21, 2012
by
Vincent Pelletier
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Stop returning uuid from identifyStorageNode as it is never altered.
In turn, stop returning uuid from identifyNode.
parent
c32895c6
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
7 additions
and
7 deletions
+7
-7
neo/master/app.py
neo/master/app.py
+3
-3
neo/master/handlers/identification.py
neo/master/handlers/identification.py
+2
-2
neo/master/recovery.py
neo/master/recovery.py
+1
-1
neo/master/verification.py
neo/master/verification.py
+1
-1
No files found.
neo/master/app.py
View file @
ff076765
...
@@ -468,7 +468,7 @@ class Application(object):
...
@@ -468,7 +468,7 @@ class Application(object):
if
uuid
is
None
or
node
is
None
:
if
uuid
is
None
or
node
is
None
:
# same as for verification
# same as for verification
state
=
NodeStates
.
PENDING
state
=
NodeStates
.
PENDING
return
uuid
,
state
,
storage
.
StorageServiceHandler
(
self
)
return
state
,
storage
.
StorageServiceHandler
(
self
)
def
identifyNode
(
self
,
node_type
,
uuid
,
node
):
def
identifyNode
(
self
,
node_type
,
uuid
,
node
):
...
@@ -497,12 +497,12 @@ class Application(object):
...
@@ -497,12 +497,12 @@ class Application(object):
manager
=
self
.
_current_manager
manager
=
self
.
_current_manager
if
manager
is
None
:
if
manager
is
None
:
manager
=
self
manager
=
self
(
uuid
,
state
,
handler
)
=
manager
.
identifyStorageNode
(
uuid
,
node
)
state
,
handler
=
manager
.
identifyStorageNode
(
uuid
,
node
)
human_readable_node_type
=
' storage (%s) '
%
(
state
,
)
human_readable_node_type
=
' storage (%s) '
%
(
state
,
)
else
:
else
:
raise
NotImplementedError
(
node_type
)
raise
NotImplementedError
(
node_type
)
logging
.
info
(
'Accept a'
+
human_readable_node_type
+
dump
(
uuid
))
logging
.
info
(
'Accept a'
+
human_readable_node_type
+
dump
(
uuid
))
return
(
uuid
,
node
,
state
,
handler
,
node_ctor
)
return
node
,
state
,
handler
,
node_ctor
def
onTransactionCommitted
(
self
,
txn
):
def
onTransactionCommitted
(
self
,
txn
):
# I have received all the lock answers now:
# I have received all the lock answers now:
...
...
neo/master/handlers/identification.py
View file @
ff076765
...
@@ -42,8 +42,8 @@ class IdentificationHandler(MasterHandler):
...
@@ -42,8 +42,8 @@ class IdentificationHandler(MasterHandler):
# ask the app the node identification, if refused, an exception is
# ask the app the node identification, if refused, an exception is
# raised
# raised
result
=
app
.
identifyNode
(
node_type
,
uuid
,
node
)
node
,
state
,
handler
,
node_ctor
=
app
.
identifyNode
(
node_type
,
uuid
,
(
uuid
,
node
,
state
,
handler
,
node_ctor
)
=
result
node
)
if
uuid
is
None
:
if
uuid
is
None
:
# no valid uuid, give it one
# no valid uuid, give it one
uuid
=
app
.
getNewUUID
(
node_type
)
uuid
=
app
.
getNewUUID
(
node_type
)
...
...
neo/master/recovery.py
View file @
ff076765
...
@@ -41,7 +41,7 @@ class RecoveryManager(MasterHandler):
...
@@ -41,7 +41,7 @@ class RecoveryManager(MasterHandler):
"""
"""
Returns the handler for storage nodes
Returns the handler for storage nodes
"""
"""
return
uuid
,
NodeStates
.
PENDING
,
self
return
NodeStates
.
PENDING
,
self
def
run
(
self
):
def
run
(
self
):
"""
"""
...
...
neo/master/verification.py
View file @
ff076765
...
@@ -89,7 +89,7 @@ class VerificationManager(BaseServiceHandler):
...
@@ -89,7 +89,7 @@ class VerificationManager(BaseServiceHandler):
# uuid from the test framework. It's safe since nodes with a
# uuid from the test framework. It's safe since nodes with a
# conflicting UUID are rejected in the identification handler.
# conflicting UUID are rejected in the identification handler.
state
=
NodeStates
.
PENDING
state
=
NodeStates
.
PENDING
return
(
uuid
,
state
,
self
)
return
state
,
self
def
run
(
self
):
def
run
(
self
):
...
...
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