Skip to content

Commit

Permalink
Synchronously delete data during defrag tests (#1443)
Browse files Browse the repository at this point in the history
The creation of fragmentation is delayed when we use lazy-free. You can
induce some of the active-defrag tests to fail by artificially adding a
delay in the lazyfree process, similar to the issues seen in #1433 and
issues like
https://github.com/valkey-io/valkey/actions/runs/12267010712/job/34226304803#step:7:6538.
The solution is to always do sync free during tests.

Might close #1433.

Signed-off-by: Madelyn Olson <[email protected]>
  • Loading branch information
madolson authored Dec 14, 2024
1 parent 3cd176d commit 0e96bb3
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions tests/unit/memefficiency.tcl
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,8 @@ run_solo {defrag} {
r config set active-defrag-ignore-bytes 2mb
r config set maxmemory 100mb
r config set maxmemory-policy allkeys-lru
r config set lazyfree-lazy-user-del no
r config set lazyfree-lazy-user-flush no

populate 700000 asdf1 150
populate 100 asdf1 150 0 false 1000
Expand Down

0 comments on commit 0e96bb3

Please sign in to comment.