"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "tests/unit/oom-score-adj.tcl" between
redis-6.2-rc3.tar.gz and redis-6.2.0.tar.gz

About: redis is an advanced key-value store. It is often referred to as a data structure server since keys can contain strings, hashes, lists, sets and sorted sets.

oom-score-adj.tcl  (redis-6.2-rc3):oom-score-adj.tcl  (redis-6.2.0)
skipping to change at line 42 skipping to change at line 42
assert {[get_oom_score_adj] == [expr $base + 20]} assert {[get_oom_score_adj] == [expr $base + 20]}
r replicaof no one r replicaof no one
assert {[get_oom_score_adj] == [expr $base + 15]} assert {[get_oom_score_adj] == [expr $base + 15]}
# Check child process # Check child process
r set key-a value-a r set key-a value-a
r config set rdb-key-save-delay 1000000 r config set rdb-key-save-delay 1000000
r bgsave r bgsave
set child_pid [get_child_pid 0] set child_pid [get_child_pid 0]
assert_equal [get_oom_score_adj $child_pid] [expr $base + 30] # Wait until background child process to setOOMScoreAdj success.
wait_for_condition 100 10 {
[get_oom_score_adj $child_pid] == [expr $base + 30]
} else {
fail "Set oom-score-adj of background child process is not ok"
}
} }
# Failed oom-score-adj tests can only run unprivileged # Failed oom-score-adj tests can only run unprivileged
if {$user_id != 0} { if {$user_id != 0} {
test {CONFIG SET oom-score-adj handles configuration failures} { test {CONFIG SET oom-score-adj handles configuration failures} {
# Bad config # Bad config
r config set oom-score-adj no r config set oom-score-adj no
r config set oom-score-adj-values "-1000 -1000 -1000" r config set oom-score-adj-values "-1000 -1000 -1000"
# Make sure it fails # Make sure it fails
 End of changes. 1 change blocks. 
1 lines changed or deleted 6 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)