README 771 B

12345678910111213141516171819
  1. The test-lru.rb program can be used in order to check the behavior of the
  2. Redis approximated LRU algorithm against the theoretical output of true
  3. LRU algorithm.
  4. In order to use the program you need to recompile Redis setting the define
  5. REDIS_LRU_CLOCK_RESOLUTION to 1, by editing the file server.h.
  6. This allows to execute the program in a fast way since the 1 ms resolution
  7. is enough for all the objects to have a different enough time stamp during
  8. the test.
  9. The program is executed like this:
  10. ruby test-lru.rb /tmp/lru.html
  11. You can optionally specify a number of times to run, so that the program
  12. will output averages of different runs, by adding an additional argument.
  13. For instance in order to run the test 10 times use:
  14. ruby test-lru.rb /tmp/lru.html 10