redict/tests/unit/type
sundb 02fd76b97c
Replace all usage of ziplist with listpack for t_hash (#8887)
Part one of implementing #8702 (taking hashes first before other types)

## Description of the feature
1. Change ziplist encoded hash objects to listpack encoding.
2. Convert existing ziplists on RDB loading time. an O(n) operation.

## Rdb format changes
1. Add RDB_TYPE_HASH_LISTPACK rdb type.
2. Bump RDB_VERSION to 10

## Interface changes
1. New `hash-max-listpack-entries` config is an alias for `hash-max-ziplist-entries` (same with `hash-max-listpack-value`)
2. OBJECT ENCODING will return `listpack` instead of `ziplist`

## Listpack improvements:
1. Support direct insert, replace integer element (rather than convert back and forth from string)
3. Add more listpack capabilities to match the ziplist ones (like `lpFind`, `lpRandomPairs` and such)
4. Optimize element length fetching, avoid multiple calculations
5. Use inline to avoid function call overhead.

## Tests
1. Add a new test to the RDB load time conversion
2. Adding the listpack unit tests. (based on the one in ziplist.c)
3. Add a few "corrupt payload: fuzzer findings" tests, and slightly modify existing ones.

Co-authored-by: Oran Agra <oran@redislabs.com>
2021-08-10 09:18:49 +03:00
..
hash.tcl Replace all usage of ziplist with listpack for t_hash (#8887) 2021-08-10 09:18:49 +03:00
incr.tcl Improve test suite to handle external servers better. (#9033) 2021-06-09 15:13:24 +03:00
list-2.tcl Minor improvements for list-2 test (#8156) 2020-12-08 16:26:38 +02:00
list-3.tcl Improve test suite to handle external servers better. (#9033) 2021-06-09 15:13:24 +03:00
list-common.tcl list test split into smaller parts 2011-07-11 11:30:46 +02:00
list.tcl Improve test suite to handle external servers better. (#9033) 2021-06-09 15:13:24 +03:00
set.tcl Add SINTERCARD/ZINTERCARD Commands (#8946) 2021-08-03 11:45:27 +03:00
stream-cgroups.tcl Fixed some typos, add a spell check ci and others minor fix (#8890) 2021-06-10 15:39:33 +03:00
stream.tcl Fix XINFO help for unexpected options. (#9075) 2021-06-15 10:01:11 +03:00
string.tcl Improve test suite to handle external servers better. (#9033) 2021-06-09 15:13:24 +03:00
zset.tcl Add SINTERCARD/ZINTERCARD Commands (#8946) 2021-08-03 11:45:27 +03:00