Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
ruanhaishen
redis
Commits
5d180d28
Unverified
Commit
5d180d28
authored
Mar 02, 2021
by
Yossi Gottlieb
Committed by
GitHub
Mar 02, 2021
Browse files
Fix potential replication-4 test race condition. (#8583)
Co-authored-by:
Oran Agra
<
oran@redislabs.com
>
parent
0bad00d0
Changes
1
Hide whitespace changes
Inline
Side-by-side
tests/integration/replication-4.tcl
View file @
5d180d28
...
@@ -79,12 +79,16 @@ start_server {tags {"repl"}} {
...
@@ -79,12 +79,16 @@ start_server {tags {"repl"}} {
$master config set min-slaves-max-lag 2
$master config set min-slaves-max-lag 2
$master config set min-slaves-to-write 1
$master config set min-slaves-to-write 1
assert
{[
$master
set foo bar
]
eq
{
OK
}}
assert
{[
$master
set foo bar
]
eq
{
OK
}}
$slave deferred 1
exec kill -SIGSTOP
[
srv 0 pid
]
$slave debug sleep 6
wait_for_condition 100 100
{
after 4000
[
catch
{
$master
set foo bar
}]
!= 0
catch
{
$master
set foo bar
}
e
}
else
{
set e
fail
"Master didn't become readonly"
}
{
NOREPLICAS*
}
}
catch
{
$master
set foo bar
}
err
assert_match
{
NOREPLICAS*
}
$err
exec kill -SIGCONT
[
srv 0 pid
]
}
}
}
}
}
...
...
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