Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
N
neoppod
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
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Xavier Thompson
neoppod
Commits
4eae1f6b
Commit
4eae1f6b
authored
Feb 20, 2012
by
Julien Muchembled
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
master: simplify import of 'NotReadyError' in app.py
parent
23e38173
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
4 deletions
+3
-4
neo/master/app.py
neo/master/app.py
+3
-4
No files found.
neo/master/app.py
View file @
4eae1f6b
...
...
@@ -19,10 +19,9 @@ import neo
import
os
,
sys
from
time
import
time
from
neo.lib
import
protocol
from
neo.lib.connector
import
getConnectorHandler
from
neo.lib.debug
import
register
as
registerLiveDebugger
from
neo.lib.protocol
import
UUID_NAMESPACES
,
ZERO_TID
from
neo.lib.protocol
import
UUID_NAMESPACES
,
ZERO_TID
,
NotReadyError
from
neo.lib.protocol
import
ClusterStates
,
NodeStates
,
NodeTypes
,
Packets
from
neo.lib.node
import
NodeManager
from
neo.lib.event
import
EventManager
...
...
@@ -446,7 +445,7 @@ class Application(object):
state
=
NodeStates
.
PENDING
handler
=
storage
.
StorageServiceHandler
(
self
)
elif
self
.
cluster_state
==
ClusterStates
.
STOPPING
:
raise
protocol
.
NotReadyError
raise
NotReadyError
else
:
raise
RuntimeError
(
'unhandled cluster state: %s'
%
(
self
.
cluster_state
,
))
...
...
@@ -470,7 +469,7 @@ class Application(object):
# refuse any client before running
if
self
.
cluster_state
!=
ClusterStates
.
RUNNING
:
neo
.
lib
.
logging
.
info
(
'Reject a connection from a client'
)
raise
protocol
.
NotReadyError
raise
NotReadyError
node_ctor
=
self
.
nm
.
createClient
handler
=
client
.
ClientServiceHandler
(
self
)
neo
.
lib
.
logging
.
info
(
'Accept a client %s'
%
(
dump
(
uuid
),
))
...
...
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