Commit 5b05a68d authored by Per Cederqvist's avatar Per Cederqvist
Browse files

Set the sync interval to 1 day, to avoid spurious save async messages

on slow hosts.  Don't change the timeout.  Keep waiting as long as the
server processes new requests, even if it is so slow that it takes a
long while for the output queue to start filling up.
(req_rate): New proc.
parent 5c30cb53
......@@ -25,6 +25,7 @@
lyskomd_start "" "Stale timeout: 10 seconds
Max client message size: 512
Sync interval: 1 days
Max client transmit queue bytes: 2505"
proc monitor_progress {} {
......@@ -54,6 +55,32 @@ proc monitor_progress {} {
unset test
}
proc req_rate {} {
global test
global spawn_id
global any_num
global any_float
global req_rate_rate
if {[info exists test]} {
set oldtest $test
unset test
}
set id $spawn_id
talk_to client 0
send "998 112 [holl "reqs"]\n"
extracting_expect "=998 6 { $any_num 0 0 $any_float $any_float $any_float $any_float $any_float ($any_float) $any_float $any_float $any_float $any_float $any_float $any_float $any_float $any_float $any_float }" req_rate_rate 1
if {[info exists oldtest]} {
set test $oldtest
}
set spawn_id $id
return $req_rate_rate
}
proc send_queue_size {} {
global test
global spawn_id
......@@ -128,10 +155,6 @@ talk_to lyskomd
# The server will wait 10 seconds before it kills the stalled client.
# Give it 4 extra seconds.
set oldtimeout $timeout
if {$timeout < 14} {
set timeout 14
}
set test "server kills client 5"
expect {
-re "Client 6 from $any* has stalled\. Killing it\.$nl" {
......@@ -139,10 +162,14 @@ expect {
}
timeout {
set size [send_queue_size]
set rate [req_rate]
if {$size > $oldsize} {
set oldsize $size
send_user "Queue is growing... $size\n"
exp_continue
} elseif {$rate > 10} {
send_user "Server is processing... $rate reqs/second (15 s avg) (size $size)\n"
exp_continue
} else {
fail "$test (output queue not growing)"
talk_to get_time_client 4
......@@ -151,7 +178,6 @@ expect {
}
}
unset test
set timeout $oldtimeout
talk_to get_time_client 4
send "ping\n"
......
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