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
ef8f00ca
Commit
ef8f00ca
authored
Jan 13, 2012
by
Vincent Pelletier
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Micro-optimisations.
parent
b6475dc3
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
4 deletions
+5
-4
neo/lib/event.py
neo/lib/event.py
+4
-3
neo/lib/node.py
neo/lib/node.py
+1
-1
No files found.
neo/lib/event.py
View file @
ef8f00ca
...
@@ -26,8 +26,8 @@ class EpollEventManager(object):
...
@@ -26,8 +26,8 @@ class EpollEventManager(object):
def
__init__
(
self
):
def
__init__
(
self
):
self
.
connection_dict
=
{}
self
.
connection_dict
=
{}
self
.
reader_set
=
set
(
[]
)
self
.
reader_set
=
set
()
self
.
writer_set
=
set
(
[]
)
self
.
writer_set
=
set
()
self
.
epoll
=
epoll
()
self
.
epoll
=
epoll
()
self
.
_pending_processing
=
[]
self
.
_pending_processing
=
[]
...
@@ -38,7 +38,8 @@ class EpollEventManager(object):
...
@@ -38,7 +38,8 @@ class EpollEventManager(object):
def
getConnectionList
(
self
):
def
getConnectionList
(
self
):
# XXX: use index
# XXX: use index
return
[
x
for
x
in
self
.
connection_dict
.
values
()
if
not
x
.
isAborted
()]
return
[
x
for
x
in
self
.
connection_dict
.
itervalues
()
if
not
x
.
isAborted
()]
def
getClientList
(
self
):
def
getClientList
(
self
):
# XXX: use index
# XXX: use index
...
...
neo/lib/node.py
View file @
ef8f00ca
...
@@ -410,7 +410,7 @@ class NodeManager(object):
...
@@ -410,7 +410,7 @@ class NodeManager(object):
if
pool_set
is
not
None
:
if
pool_set
is
not
None
:
identified_nodes
=
self
.
_identified_dict
.
items
()
identified_nodes
=
self
.
_identified_dict
.
items
()
return
[
v
for
k
,
v
in
identified_nodes
if
k
in
pool_set
]
return
[
v
for
k
,
v
in
identified_nodes
if
k
in
pool_set
]
return
list
(
self
.
_identified_dict
.
values
()
)
return
self
.
_identified_dict
.
values
(
)
def
getConnectedList
(
self
):
def
getConnectedList
(
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