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
Levin Zimmermann
neoppod
Commits
9c8502ed
Commit
9c8502ed
authored
Nov 10, 2016
by
Kirill Smelkov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
.
parent
d48930fe
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
5 additions
and
11 deletions
+5
-11
neo/lib/event.py
neo/lib/event.py
+1
-2
neo/storage/handlers/client.py
neo/storage/handlers/client.py
+3
-4
neo/storage/handlers/identification.py
neo/storage/handlers/identification.py
+0
-1
neo/storage/replicator.py
neo/storage/replicator.py
+0
-1
neo/tests/master/testClientHandler.py
neo/tests/master/testClientHandler.py
+1
-1
neo/tests/threaded/__init__.py
neo/tests/threaded/__init__.py
+0
-1
tools/replication
tools/replication
+0
-1
No files found.
neo/lib/event.py
View file @
9c8502ed
...
...
@@ -136,8 +136,7 @@ class EpollEventManager(object):
if
self
.
_closeAcquire
(
0
):
self
.
_closeRelease
()
# NOTE
def
isIdle
(
self
):
def
isIdle
(
self
):
# NOTE
return
not
(
self
.
_pending_processing
or
self
.
writer_set
)
def
_addPendingConnection
(
self
,
conn
):
...
...
neo/storage/handlers/client.py
View file @
9c8502ed
...
...
@@ -23,8 +23,6 @@ from ..transactions import ConflictError, DelayedError, NotRegisteredError
from
..exception
import
AlreadyPendingError
import
time
import
traceback
# Log stores taking (incl. lock delays) more than this many seconds.
# Set to None to disable.
SLOW_STORE
=
2
...
...
@@ -47,7 +45,6 @@ class ClientOperationHandler(EventHandler):
app
.
queueEvent
(
self
.
askObject
,
conn
,
(
oid
,
serial
,
tid
))
return
o
=
app
.
dm
.
getObject
(
oid
,
serial
,
tid
)
print
'askObject -> %r'
%
(
o
,)
try
:
serial
,
next_serial
,
compression
,
checksum
,
data
,
data_serial
=
o
except
TypeError
:
...
...
@@ -242,7 +239,6 @@ class ClientROOperationHandler(ClientOperationHandler):
askVoteTransaction
=
_readOnly
askStoreObject
=
_readOnly
askFinalTID
=
_readOnly
# askObjectUndoSerial is used in undo() but itself is read-only query XXX or cut <= backup_tid ?
askCheckCurrentSerial
=
_readOnly
# takes write lock & is only used when going to commit
# below operations: like in ClientOperationHandler but cut tid <= backup_tid
...
...
@@ -284,6 +280,9 @@ class ClientROOperationHandler(ClientOperationHandler):
tid_list
=
filter
(
lambda
tid
:
tid
<=
backup_tid
,
tid_list
)
conn
.
answer
(
Packets
.
AnswerTIDs
(
tid_list
))
# FIXME askObjectUndoSerial to limit tid <= backup_tid
# (askObjectUndoSerial is used in undo() but itself is read-only query)
# FIXME askObjectHistory to limit tid <= backup_tid
# TODO dm.getObjectHistory has to be first fixed for this
#def askObjectHistory(self, conn, oid, first, last):
neo/storage/handlers/identification.py
View file @
9c8502ed
...
...
@@ -70,7 +70,6 @@ class IdentificationHandler(EventHandler):
else
:
raise
ProtocolError
(
'reject non-client-or-storage node'
)
# apply the handler and set up the connection
print
'S: -> handler: %s'
%
handler
handler
=
handler
(
self
.
app
)
conn
.
setHandler
(
handler
)
node
.
setConnection
(
conn
,
app
.
uuid
<
uuid
)
...
...
neo/storage/replicator.py
View file @
9c8502ed
...
...
@@ -366,7 +366,6 @@ class Replicator(object):
node
=
self
.
current_node
if
node
is
not
None
is
node
.
getUUID
():
self
.
cancel
()
# NOTE
# Cancel all replication orders from upstream cluster.
for
offset
in
self
.
replicate_dict
.
keys
():
addr
,
name
=
self
.
source_dict
.
get
(
offset
,
(
None
,
None
))
...
...
neo/tests/master/testClientHandler.py
View file @
9c8502ed
...
...
@@ -34,7 +34,7 @@ class MasterClientHandlerTests(NeoUnitTestBase):
self
.
app
.
em
=
Mock
()
self
.
app
.
loid
=
'
\
0
'
*
8
self
.
app
.
tm
.
setLastTID
(
'
\
0
'
*
8
)
self
.
service
=
ClientServiceHandler
(
self
.
app
)
# TODO tests for RO handler
self
.
service
=
ClientServiceHandler
(
self
.
app
)
# define some variable to simulate client and storage node
self
.
client_port
=
11022
self
.
storage_port
=
10021
...
...
neo/tests/threaded/__init__.py
View file @
9c8502ed
...
...
@@ -751,7 +751,6 @@ class NEOCluster(object):
self
.
enableStorageList
(
storage_list
)
def
newClient
(
self
):
print
'%r: newClient()'
%
self
return
ClientApplication
(
name
=
self
.
name
,
master_nodes
=
self
.
master_nodes
,
compress
=
self
.
compress
,
ssl
=
self
.
SSL
)
...
...
tools/replication
View file @
9c8502ed
...
...
@@ -33,7 +33,6 @@ class DummyObject(Persistent):
def
__init__
(
self
,
data
):
self
.
_data
=
None
# NOTE
class
ReplicationBenchmark
(
BenchmarkRunner
):
""" Test replication process """
...
...
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