1. 22 Feb, 2021 2 commits
    • Greg Femec's avatar
      Fix random element selection for large hash tables. (#8133) · cde69883
      Greg Femec authored
      
      
      When a database on a 64 bit build grows past 2^31 keys, the underlying hash table expands to 2^32 buckets. After this point, the algorithms for selecting random elements only return elements from half of the available buckets because they use random() which has a range of 0 to 2^31 - 1. This causes problems for eviction policies which use dictGetSomeKeys or dictGetRandomKey. Over time they cause the hash table to become unbalanced because, while new keys are spread out evenly across all buckets, evictions come from only half of the available buckets. Eventually this half of the table starts to run out of keys and it takes longer and longer to find candidates for eviction. This continues until no more evictions can happen.
      
      This solution addresses this by using a 64 bit PRNG instead of libc random().
      Co-authored-by: default avatarGreg Femec <gfemec@google.com>
      (cherry picked from commit 266949c7)
      cde69883
    • filipe oliveira's avatar
      redis-benchmark: Fix broken protocol when used with -a or --dbnum (#8486) · 840b393c
      filipe oliveira authored
      Fix the pointers to the slot hash tags in the case of prefixed commands usage
      i.e. AUTH / SELECT
      
      It adjusts the pointers to the slot hash tags in the case of prefixed commands
      usage as soon as we get the 1st reply (same like we already did for the random
      strings within the command )
      
      (cherry picked from commit efccd635)
      840b393c
  2. 27 Oct, 2020 1 commit
  3. 01 Sep, 2020 3 commits
  4. 20 Jul, 2020 1 commit
  5. 22 May, 2020 2 commits
  6. 09 May, 2020 1 commit
  7. 08 May, 2020 1 commit
  8. 22 Jul, 2019 1 commit
  9. 05 Jun, 2019 1 commit
  10. 26 Apr, 2019 2 commits
  11. 24 Apr, 2019 1 commit
  12. 08 Apr, 2019 1 commit
  13. 13 Mar, 2019 1 commit
  14. 12 Mar, 2019 1 commit
  15. 08 Mar, 2019 1 commit
  16. 07 Mar, 2019 2 commits
  17. 01 Mar, 2019 12 commits
  18. 26 Feb, 2019 1 commit
  19. 18 Feb, 2019 1 commit
  20. 14 Feb, 2019 1 commit
  21. 13 Feb, 2019 2 commits
  22. 03 Jan, 2018 1 commit