Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
I
irker
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Package Registry
Model registry
Operate
Terraform modules
Analyze
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
iDB
irker
Commits
c6e9ebde
Commit
c6e9ebde
authored
3 years ago
by
Vijver, van de, Bob (UT-GUEST)
Browse files
Options
Downloads
Patches
Plain Diff
Use xmit in ping timeout window to determine broken connection correctly
parent
93f58858
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
irkerd
+2
-1
2 additions, 1 deletion
irkerd
with
2 additions
and
1 deletion
irkerd
+
2
−
1
View file @
c6e9ebde
...
@@ -555,11 +555,12 @@ class Connection:
...
@@ -555,11 +555,12 @@ class Connection:
now
=
time
.
time
()
now
=
time
.
time
()
xmit_timeout
=
now
>
self
.
last_xmit
+
XMIT_TTL
xmit_timeout
=
now
>
self
.
last_xmit
+
XMIT_TTL
ping_timeout
=
now
>
self
.
last_ping
+
PING_TTL
ping_timeout
=
now
>
self
.
last_ping
+
PING_TTL
xmit_in_ping_timeout
=
self
.
last_xmit
+
PING_TTL
>
self
.
last_ping
if
self
.
status
==
"
disconnected
"
:
if
self
.
status
==
"
disconnected
"
:
# If the queue is empty, we can drop this connection.
# If the queue is empty, we can drop this connection.
self
.
status
=
"
expired
"
self
.
status
=
"
expired
"
break
break
elif
ping_timeout
:
elif
not
xmit_in_ping_timeout
and
ping_timeout
:
LOG
.
info
((
LOG
.
info
((
"
timing out connection to %s at %s
"
"
timing out connection to %s at %s
"
"
(ping_timeout=%s, xmit_timeout=%s)
"
)
%
(
"
(ping_timeout=%s, xmit_timeout=%s)
"
)
%
(
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment