Commit 91fcd98b authored by Aurel's avatar Aurel

add new exception for connection failure with a storage node


git-svn-id: https://svn.erp5.org/repos/neo/branches/prototype3@581 71dcc9de-d417-0410-9af5-da40c76e7ee4
parent 18f8d2b3
......@@ -32,7 +32,7 @@ from neo.protocol import Packet, INVALID_UUID, INVALID_TID, INVALID_PARTITION, \
INVALID_PTID, CLIENT_NODE_TYPE, UP_TO_DATE_STATE, INVALID_SERIAL
from neo.client.handler import *
from neo.client.exception import NEOStorageError, NEOStorageConflictError, \
NEOStorageNotFoundError
NEOStorageNotFoundError, NEOStorageConnectionFailure
from neo.util import makeChecksum, dump
from neo.connector import getConnectorHandler
from neo.client.dispatcher import Dispatcher
......@@ -290,7 +290,7 @@ class Application(object):
break
if packet is None:
if conn is target_conn:
raise NEOStorageError('connection closed')
raise NEOStorageConnectionFailure('connection closed')
else:
continue
handler.dispatch(conn, packet)
......
......@@ -19,4 +19,4 @@ from ZODB import POSException
class NEOStorageError(POSException.StorageError): pass
class NEOStorageConflictError(NEOStorageError): pass
class NEOStorageNotFoundError(NEOStorageError): pass
class NEOStorageConnectionFailure(NEOStorageError): pass
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment