1. 23 Aug, 2022 1 commit
    • Oran Agra's avatar
      Build TLS as a loadable module · 4faddf18
      Oran Agra authored
      
      
      * Support BUILD_TLS=module to be loaded as a module via config file or
        command line. e.g. redis-server --loadmodule redis-tls.so
      * Updates to redismodule.h to allow it to be used side by side with
        server.h by defining REDISMODULE_CORE_MODULE
      * Changes to server.h, redismodule.h and module.c to avoid repeated
        type declarations (gcc 4.8 doesn't like these)
      * Add a mechanism for non-ABI neutral modules (ones who include
        server.h) to refuse loading if they detect not being built together with
        redis (release.c)
      * Fix wrong signature of RedisModuleDefragFunc, this could break
        compilation of a module, but not the ABI
      * Move initialization of listeners in server.c to be after loading
        the modules
      * Config TLS after initialization of listeners
      * Init cluster after initialization of listeners
      * Add TLS module to CI
      * Fix a test suite race conditions:
        Now that the listeners are initialized later, it's not sufficient to
        wait for the PID message in the log, we need to wait for the "Server
        Initialized" message.
      * Fix issues with moduleconfigs test as a result from start_server
        waiting for "Server Initialized"
      * Fix issues with modules/infra test as a result of an additional module
        present
      
      Notes about Sentinel:
      Sentinel can't really rely on the tls module, since it uses hiredis to
      initiate connections and depends on OpenSSL (won't be able to use any
      other connection modules for that), so it was decided that when TLS is
      built as a module, sentinel does not support TLS at all.
      This means that it keeps using redis_tls_ctx and redis_tls_client_ctx directly.
      
      Example code of config in redis-tls.so(may be use in the future):
      RedisModuleString *tls_cfg = NULL;
      
      void tlsInfo(RedisModuleInfoCtx *ctx, int for_crash_report) {
          UNUSED(for_crash_report);
          RedisModule_InfoAddSection(ctx, "");
          RedisModule_InfoAddFieldLongLong(ctx, "var", 42);
      }
      
      int tlsCommand(RedisModuleCtx *ctx, RedisModuleString **argv, int argc)
      {
          if (argc != 2) return RedisModule_WrongArity(ctx);
          return RedisModule_ReplyWithString(ctx, argv[1]);
      }
      
      RedisModuleString *getStringConfigCommand(const char *name, void *privdata) {
          REDISMODULE_NOT_USED(name);
          REDISMODULE_NOT_USED(privdata);
          return tls_cfg;
      }
      
      int setStringConfigCommand(const char *name, RedisModuleString *new, void *privdata, RedisModuleString **err) {
          REDISMODULE_NOT_USED(name);
          REDISMODULE_NOT_USED(err);
          REDISMODULE_NOT_USED(privdata);
          if (tls_cfg) RedisModule_FreeString(NULL, tls_cfg);
          RedisModule_RetainString(NULL, new);
          tls_cfg = new;
          return REDISMODULE_OK;
      }
      
      int RedisModule_OnLoad(void *ctx, RedisModuleString **argv, int argc)
      {
          ....
          if (RedisModule_CreateCommand(ctx,"tls",tlsCommand,"",0,0,0) == REDISMODULE_ERR)
              return REDISMODULE_ERR;
      
          if (RedisModule_RegisterStringConfig(ctx, "cfg", "", REDISMODULE_CONFIG_DEFAULT, getStringConfigCommand, setStringConfigCommand, NULL, NULL) == REDISMODULE_ERR)
              return REDISMODULE_ERR;
      
          if (RedisModule_LoadConfigs(ctx) == REDISMODULE_ERR) {
              if (tls_cfg) {
                  RedisModule_FreeString(ctx, tls_cfg);
                  tls_cfg = NULL;
              }
              return REDISMODULE_ERR;
          }
          ...
      }
      Co-authored-by: default avatarzhenwei pi <pizhenwei@bytedance.com>
      Signed-off-by: default avatarzhenwei pi <pizhenwei@bytedance.com>
      4faddf18
  2. 02 Aug, 2022 1 commit
  3. 19 Jul, 2022 1 commit
  4. 04 May, 2022 1 commit
  5. 12 Apr, 2022 1 commit
  6. 30 Mar, 2022 2 commits
  7. 29 Mar, 2022 1 commit
    • Oran Agra's avatar
      fix daily.yaml skip filters (#10490) · 16d206ee
      Oran Agra authored
      * missing parenthesis meant that the ubuntu and centos jobs were not
        skipped
      * the recently divided freebsd, macos, and valgrind jobs, which are now
        split into distict jobs for redis, modules, sentinel, cluster. were
        all executed, producing a build, but not running anything.
        now they're filtered at the job level
      * iothreads was missing from the skip list defaults, so was not skipped
      16d206ee
  8. 22 Mar, 2022 1 commit
  9. 09 Mar, 2022 1 commit
  10. 28 Feb, 2022 1 commit
  11. 14 Feb, 2022 1 commit
    • Yossi Gottlieb's avatar
      Squashed 'deps/hiredis/' changes from 00272d669..f8de9a4bd · 418de21d
      Yossi Gottlieb authored
      f8de9a4bd Merge pull request #1046 from redis/rockylinux-ci
      a41c9bc8b CentOS 8 is EOL, switch to RockyLinux
      be41ed60d Avoid incorrect call to the previous reply's callback (#1040)
      f2e8010d9 fix building on AIX and SunOS (#1031)
      e73ab2f23 Add timeout support for libuv adapter (#1016)
      f2ce5980e Allow sending commands after sending an unsubscribe (#1036)
      ff860e55d Correction for command timeout during pubsub (#1038)
      24d534493 CMakeLists.txt: allow building without a C++ compiler (#872)
      4ece9a02e Fix adapters/libevent.h compilation for 64-bit Windows (#937)
      799edfaad Don't link with crypto libs if USE_SSL isn't set.
      f74b08182 Makefile: move SSL options into a block and refine rules
      f347743b7 Update CMakeLists.txt for more portability (#1005)
      f2be74802 Fix integer overflow when format command larger than 4GB (#1030)
      58aacdac6 Handle array response in parallell with pubsub using RESP3 (#1014)
      d3384260e Support PING while subscribing (RESP2) (#1027)
      e3a479e40 FreeBSD build fixes + CI (#1026)
      da5a4ff36 Add asynchronous test for pubsub using RESP3 (#1012)
      b5716ee82 Valgrind returns error exit code when errors found (#1011)
      1aed21a8c Move to using make directly in Cygwin (#1020)
      a83f4b890 Correct CMake warning for libevent adapter example
      c4333203e Remove unused parameter warning in libev adapter
      7ad38dc4a Small tweaks of the async tests
      4021726a6 Add asynchronous test for pubsub using RESP2
      648763c36 Add build options for enabling async tests
      c98c6994d Correcting the build target `coverage` for enabled SSL (#1009)
      30ff8d850 Run SSL tests in CI
      4a126e8a9 Add valgrind and CMake to tests
      b73c2d410 Add Centos8
      e9f647384 We should run actions on PRs
      6ad4ccf3c Add Cygwin build test
      783a3789c Add Windows tests in GitHub actions
      0cac8dae1 Switch to GitHub actions
      fa900ef76 Fix unused variable warning.
      e489846b7 Minor refactor of CVE-2021-32765 fix.
      51c740824 Remove extra comma from cmake var. Or it'll be treated as part of the var name.
      632bf0718 Merge branch 'release/v1.0.2'
      b73128324 Prepare for v1.0.2 GA
      d4e6f109a Revert erroneous SONAME bump
      a39824a5d Merge branch 'release/v1.0.1'
      8d1bfac46  Prepare for v1.0.1 GA
      76a7b1000 Fix for integer/buffer overflow CVE-2021-32765
      9eca1f36f Allow to override OPENSSL_PREFIX in Linux
      2d9d77518 Don't leak memory if an invalid type is set (#906)
      f5f31ff9b Added REDIS_NO_AUTO_FREE_REPLIES flag (#962)
      5850a8ecd Ensure we curry any connect error to an async context.
      b6f86f38c Fix README.md
      667dbf536 Merge pull request #935 from kristjanvalur/pr5
      9bf6c250e Merge pull request #939 from zmartzone/improve_pr_896_ssl_leak
      959af9760 Merge pull request #949 from plan-do-break-fix/Typo-corrections
      0743f57bb fix(docs): corrects typos in project README
      5f4382247 improve SSL leak fix redis/hiredis#896
      e06ecf7e4 Ignore timeout callback from a successful connect
      dfa33e60b Change order independant push logic to not change behavior.
      6204182aa Handle the case where an invalidation is sent second.
      d6a0b192b Merge branch 'reader-updates'
      410c24d2a Fix off-by-one error in seekNewline
      bd7488d27 read: Validate line items prior to checking for object creation callbacks
      5f9242a1f read: Remove obsolete comment on nested multi bulk depth limitation
      83c145042 read: Add support for the RESP3 bignum type
      c6646cb19 read: Ensure no invalid '\r' or '\n' in simple status/error strings
      e43061156 read: Additional validation and test case for RESP3 double
      c8adea402 redisReply: Fix parent type assertions during double, nil, bool creation
      ff73f1f9e redisReply: Explicitly list nil and bool cases in freeReplyObject() switch.
      0f9251884 test: Add test case for RESP3 set
      33c06dd50 test: Add test case for RESP3 map
      397fe2630 read: Use memchr() in seekNewline() instead of looping over entire string
      81c48a982 test: Add test cases for RESP3 bool
      51e693f4f read: Add additional RESP3 bool validation
      790b4d3b4 test: Add test cases for RESP3 nil
      d8899fbc1 read: Add additional RESP3 nil validation
      96e8ea611 test: Add test cases for infinite and NaN doubles
      f913e9b99 read: Fix double validation and infinity parsing
      8039c7d26 test: Add test case for doubles
      49539fd1a redisReply: Fix - set len in double objects
      53a8144c8 Merge pull request #924 from cheese1/master
      9390de006 http -> https
      7d99b5635 Merge pull request #917 from Nordix/stack-alloc-dict-iter
      4bba72103 Handle OOM during async command callback registration
      920128a26 Stack allocate dict iterators
      297ecbecb Tiny formatting changes + suppress implicit memcpy warning
      f746a28e7 Removed 2 typecasts
      940a04f4d Added fuzzer
      e4a200040 Merge pull request #896 from ayeganov/bugfix/ssl_leak
      aefef8987 Free SSL object when redisSSLConnect fails
      e3f88ebcf Merge pull request #894 from jcohen02/fix/issue893
      308ffcab8 Updating SSL connection example
      297f6551d Merge pull request #889 from redis/wincert
      e7dda9785 Formatting
      f44945a0a Merge pull request #874 from masariello/position-independent-code
      74e78498c Merge pull request #888 from michael-grunder/nil-push-invalidation
      b9b9f446f Fix handling of NIL invalidation messages.
      acc917548 Merge pull request #885 from gkorland/patch-1
      b086f763e clean a warning, remvoe empty else block
      b47fae4e7 Merge pull request #881 from timgates42/bugfix_typo_terminated
      f989670e5 docs: Fix simple typo, termined -> terminated
      773d6ea8a Copy error to redisAsyncContext on timeout
      e35300a66 add pdb files to packages for MSVC builds
      dde6916b4 Add d suffix to debug libraries so that can packaged together with optimized builds (Release, RelWithDebInfo, etc)
      3b68b5018 Enable position-independent code
      6693863f4 Add support for system CA certificate store on Windows
      2a5a57b90 Remove whitespace
      1b40ec509 fixed issue with unit test linking on windows with SSL
      d7b1d21e8 Merge branch 'master' of github.com:redis/hiredis
      fb0e6c0dd Merge pull request #870 from michael-grunder/cmake-c99
      13a35bdb6 Explicitly set c99 in CMake
      bea137ca9 Merge pull request #868 from michael-grunder/fix-sockaddr-typo
      bd6f86eb6 Fix sockaddr typo
      48696e7e5 Don't use non-installed win32.h helper in examples (#863)
      faa1c4863 Merge tag 'v1.0.0'
      5003906d6 Define a no op assert if we detect NDEBUG (#861)
      ea063b7cc Use development specific versions in master
      04a27f480 We can run SSL tests everywhere except mingw/Windows (#859)
      8966a1fc2 Remove extra whitespace (#858)
      34b7f7a0f Keep libev's code style (#857)
      07c3618ff Add static library target and cpack support
      REVERT: 00272d669 Rename sds calls so they don't conflict in Redis.
      
      git-subtree-dir: deps/hiredis
      git-subtree-split: f8de9a4bd433791890572f7b9147e685653ddef9
      418de21d
  12. 13 Feb, 2022 1 commit
  13. 02 Feb, 2022 1 commit
  14. 29 Jan, 2022 1 commit
  15. 04 Jan, 2022 1 commit
  16. 19 Dec, 2021 2 commits
    • Oran Agra's avatar
      Add external test that runs without debug command (#9964) · 6add1b72
      Oran Agra authored
      - add needs:debug flag for some tests
      - disable "save" in external tests (speedup?)
      - use debug_digest proc instead of debug command directly so it can be skipped
      - use OBJECT ENCODING instead of DEBUG OBJECT to get encoding
      - add a proc for OBJECT REFCOUNT so it can be skipped
      - move a bunch of tests in latency_monitor tests to happen later so that latency monitor has some values in it
      - add missing close_replication_stream calls
      - make sure to close the temp client if DEBUG LOG fails
      6add1b72
    • YaacovHazan's avatar
      Protected configs and sensitive commands (#9920) · ae2f5b7b
      YaacovHazan authored
      Block sensitive configs and commands by default.
      
      * `enable-protected-configs` - block modification of configs with the new `PROTECTED_CONFIG` flag.
         Currently we add this flag to `dbfilename`, and `dir` configs,
         all of which are non-mutable configs that can set a file redis will write to.
      * `enable-debug-command` - block the `DEBUG` command
      * `enable-module-command` - block the `MODULE` command
      
      These have a default value set to `no`, so that these features are not
      exposed by default to client connections, and can only be set by modifying the config file.
      
      Users can change each of these to either `yes` (allow all access), or `local` (allow access from
      local TCP connections and unix domain connections)
      
      Note that this is a **breaking change** (specifically the part about MODULE command being disabled by default).
      I.e. we don't consider DEBUG command being blocked as an issue (people shouldn't have been using it),
      and the few configs we protected are unlikely to have been set at runtime anyway.
      On the other hand, it's likely to assume some users who use modules, load them from the config file anyway.
      Note that's the whole point of this PR, for redis to be more secure by default and reduce the attack surface on
      innocent users, so secure defaults will necessarily mean a breaking change.
      ae2f5b7b
  17. 29 Nov, 2021 1 commit
    • Binbin's avatar
      Add REDIS_CFLAGS='-Werror' to CI tests (#9828) · 980bb3ae
      Binbin authored
      Update CI so that warnings cause build failures.
      
      Also fix a warning in `test-sanitizer-address`:
      ```
      In function ‘strncpy’,
         inlined from ‘clusterUpdateMyselfIp’ at cluster.c:545:13:
      
      /usr/include/x86_64-linux-gnu/bits/string_fortified.h:106:10:
      error: ‘__builtin_strncpy’ specified bound 46 equals destination size [-Werror=stringop-truncation]
      
        106 |   return __builtin___strncpy_chk (__dest, __src, __len, __bos (__dest));
            |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
      cc1: all warnings being treated as errors
      ```
      980bb3ae
  18. 28 Nov, 2021 1 commit
    • Meir Shpilraien (Spielrein)'s avatar
      Fix Lua C API violation on lua msgpack lib. (#9832) · a8c1253b
      Meir Shpilraien (Spielrein) authored
      msgpack lib missed using lua_checkstack and so on rare
      cases overflow the stack by at most 2 elements. This is a
      violation of the Lua C API. Notice that Lua allocates
      additional 5 more elements on top of lua->stack_last
      so Redis does not access an invalid memory. But it is an
      API violation and we should avoid it.
      
      This PR also added a new Lua compilation option. The new
      option can be enable using environment variable called
      LUA_DEBUG. If set to `yes` (by default `no`), Lua will be
      compiled without optimizations and with debug symbols (`-O0 -g`).
      In addition, in this new mode, Lua will be compiled with the
      `-DLUA_USE_APICHECK` flag that enables extended Lua C API
      validations.
      
      In addition, set LUA_DEBUG=yes on daily valgrind flow so we
      will be able to catch Lua C API violations in the future.
      a8c1253b
  19. 21 Nov, 2021 1 commit
  20. 18 Nov, 2021 1 commit
  21. 16 Nov, 2021 1 commit
    • Oran Agra's avatar
      Daily tests flags inconsistency (#9792) · 45144fc7
      Oran Agra authored
      Add --accurate to unit tests (new feature recently added)
      Add --no-latency to valgrind run (was present only for modules)
      add --no-latency to macos and freebsd runs (was not present for modules)
      add --timeout to freebsd (same one we have for valgrind)
      45144fc7
  22. 11 Nov, 2021 3 commits
    • Ozan Tezcan's avatar
      Enable running daily CI from forks (#9771) · bcb7961f
      Ozan Tezcan authored
      Was impossible to run the daily CI from private forks due to "redis/redis" repo check.
      Let's disable that check for manual triggers.
      bcb7961f
    • Ozan Tezcan's avatar
      Add sanitizer support and clean up sanitizer findings (#9601) · b91d8b28
      Ozan Tezcan authored
      - Added sanitizer support. `address`, `undefined` and `thread` sanitizers are available.  
      - To build Redis with desired sanitizer : `make SANITIZER=undefined`
      - There were some sanitizer findings, cleaned up codebase
      - Added tests with address and undefined behavior sanitizers to daily CI.
      - Added tests with address sanitizer to the per-PR CI (smoke out mem leaks sooner).
      
      Basically, there are three types of issues : 
      
      **1- Unaligned load/store** : Most probably, this issue may cause a crash on a platform that
      does not support unaligned access. Redis does unaligned access only on supported platforms.
      
      **2- Signed integer overflow.** Although, signed overflow issue can be problematic time to time
      and change how compiler generates code, current findings mostly about signed shift or simple
      addition overflow. For most platforms Redis can be compiled for, this wouldn't cause any issue
      as far as I can tell (checked generated code on godbolt.org).
      
       **3 -Minor leak** (redis-cli), **use-after-free**(just before calling exit());
      
      UB means nothing guaranteed and risky to reason about program behavior but I don't think any
      of the fixes here worth backporting. As sanitizers are now part of the CI, preventing new issues
      will be the real benefit. 
      b91d8b28
    • yoav-steinberg's avatar
      Archive external redis log in external tests (#9765) · cd6b3d55
      yoav-steinberg authored
      On test failure store the external redis server logs as CI artifacts so we can review them.
      
      Write test name to server log for external server tests.
      This is attempted and silently failed in case external server doesn't support it.
      Note that in non-external server mode we use a more robust method of writing to the log which doesn't depend on the
      server actually running/working. This isn't possible for externl servers and required for some complex tests which are
      skipped in external mode anyway.
      
      Cleanup: remove dup code.
      cd6b3d55
  23. 10 Nov, 2021 2 commits
    • Oran Agra's avatar
      Try solving test timeout on freebsd CI (#9768) · 0927a0dd
      Oran Agra authored
      First, avoid using --accurate on the freebsd CI, we only care about
      systematic issues there due to being different platform, but not
      accuracy
      
      Secondly, when looking at the test which timed out it seems silly and
      outdated:
      - it used KEYS to attempt to trigger lazy expiry, but KEYS doesn't do
        that anymore.
      - it used some hard coded sleeps rather than waiting for things to
        happen and exiting ASAP
      0927a0dd
    • Oran Agra's avatar
      Increase test timeout in valgrind runs (#9767) · 978eadba
      Oran Agra authored
      We saw some tests sporadically time out on valgrind (namely the ones
      from #9323).
      
      Increasing valgrind timeout from 20 mins to 40 mins in CI.
      And fixing an outdated help message.
      978eadba
  24. 09 Nov, 2021 1 commit
    • YaacovHazan's avatar
      fix short timeout in replication short read tests (#9763) · 03406fcb
      YaacovHazan authored
      In both tests, "diskless loading short read" and "diskless loading short read with module",
      the timeout of waiting for the replica to respond to a short read and log it, is too short.
      
      Also, add --dump-logs in runtest-moduleapi for valgrind runs.
      03406fcb
  25. 03 Nov, 2021 1 commit
    • perryitay's avatar
      Add support for list type to store elements larger than 4GB (#9357) · f27083a4
      perryitay authored
      
      
      Redis lists are stored in quicklist, which is currently a linked list of ziplists.
      Ziplists are limited to storing elements no larger than 4GB, so when bigger
      items are added they're getting truncated.
      This PR changes quicklists so that they're capable of storing large items
      in quicklist nodes that are plain string buffers rather than ziplist.
      
      As part of the PR there were few other changes in redis: 
      1. new DEBUG sub-commands: 
         - QUICKLIST-PACKED-THRESHOLD - set the threshold of for the node type to
           be plan or ziplist. default (1GB)
         - QUICKLIST <key> - Shows low level info about the quicklist encoding of <key>
      2. rdb format change:
         - A new type was added - RDB_TYPE_LIST_QUICKLIST_2 . 
         - container type (packed / plain) was added to the beginning of the rdb object
           (before the actual node list).
      3. testing:
         - Tests that requires over 100MB will be by default skipped. a new flag was
           added to 'runtest' to run the large memory tests (not used by default)
      Co-authored-by: default avatarsundb <sundbcn@gmail.com>
      Co-authored-by: default avatarOran Agra <oran@redislabs.com>
      f27083a4
  26. 16 Oct, 2021 1 commit
  27. 11 Aug, 2021 1 commit
    • Yossi Gottlieb's avatar
      Add debian:oldoldstable build target for CI. (#9358) · 08c46f2b
      Yossi Gottlieb authored
      Making sure Redis builds properly on older compiler is important given the wide range of systems it is built for. So far Ubuntu 16.04 has been used for this purpose, but as it's getting phased out we'll move to `oldoldstable` Debian as an "old system" precursor.
      08c46f2b
  28. 21 Jul, 2021 1 commit
    • Huang Zhw's avatar
      On 32 bit platform, the bit position of GETBIT/SETBIT/BITFIELD/BITCOUNT,BITPOS... · 71d45287
      Huang Zhw authored
      On 32 bit platform, the bit position of GETBIT/SETBIT/BITFIELD/BITCOUNT,BITPOS may overflow (see CVE-2021-32761) (#9191)
      
      GETBIT, SETBIT may access wrong address because of wrap.
      BITCOUNT and BITPOS may return wrapped results.
      BITFIELD may access the wrong address but also allocate insufficient memory and segfault (see CVE-2021-32761).
      
      This commit uses `uint64_t` or `long long` instead of `size_t`.
      related https://github.com/redis/redis/pull/8096
      
      At 32bit platform:
      > setbit bit 4294967295 1
      (integer) 0
      > config set proto-max-bulk-len 536870913
      OK
      > append bit "\xFF"
      (integer) 536870913
      > getbit bit 4294967296
      (integer) 0
      
      When the bit index is larger than 4294967295, size_t can't hold bit index. In the past,  `proto-max-bulk-len` is limit to 536870912, so there is no problem.
      
      After this commit, bit position is stored in `uint64_t` or `long long`. So when `proto-max-bulk-len > 536870912`, 32bit platforms can still be correct.
      
      For 64bit platform, this problem still exists. The major reason is bit pos 8 times of byte pos. When proto-max-bulk-len is very larger, bit pos may overflow.
      But at 64bit platform, we don't have so long string. So this bug may never happen.
      
      Additionally this commit add a test cost `512MB` memory which is tag as `large-memory`. Make freebsd ci and valgrind ci ignore this test.
      71d45287
  29. 05 Jul, 2021 1 commit
  30. 24 Jun, 2021 1 commit
    • Oran Agra's avatar
      Re-fix daily CI (#9141) · a5bc54f0
      Oran Agra authored
      The freebsd and macos jobs were still broken.
      also add a few more skip jobs options.
      a5bc54f0
  31. 23 Jun, 2021 2 commits
  32. 22 Jun, 2021 1 commit
  33. 10 Jun, 2021 1 commit
    • Binbin's avatar
      Fixed some typos, add a spell check ci and others minor fix (#8890) · 0bfccc55
      Binbin authored
      This PR adds a spell checker CI action that will fail future PRs if they introduce typos and spelling mistakes.
      This spell checker is based on blacklist of common spelling mistakes, so it will not catch everything,
      but at least it is also unlikely to cause false positives.
      
      Besides that, the PR also fixes many spelling mistakes and types, not all are a result of the spell checker we use.
      
      Here's a summary of other changes:
      1. Scanned the entire source code and fixes all sorts of typos and spelling mistakes (including missing or extra spaces).
      2. Outdated function / variable / argument names in comments
      3. Fix outdated keyspace masks error log when we check `config.notify-keyspace-events` in loadServerConfigFromString.
      4. Trim the white space at the end of line in `module.c`. Check: https://github.com/redis/redis/pull/7751
      5. Some outdated https link URLs.
      6. Fix some outdated comment. Such as:
          - In README: about the rdb, we used to said create a `thread`, change to `process`
          - dbRandomKey function coment (about the dictGetRandomKey, change to dictGetFairRandomKey)
          - notifyKeyspaceEvent fucntion comment (add type arg)
          - Some others minor fix in comment (Most of them are incorrectly quoted by variable names)
      7. Modified the error log so that users can easily distinguish between TCP and TLS in `changeBindAddr`
      0bfccc55
  34. 09 Jun, 2021 1 commit
    • Yossi Gottlieb's avatar
      Improve test suite to handle external servers better. (#9033) · 8a86bca5
      Yossi Gottlieb authored
      This commit revives the improves the ability to run the test suite against
      external servers, instead of launching and managing `redis-server` processes as
      part of the test fixture.
      
      This capability existed in the past, using the `--host` and `--port` options.
      However, it was quite limited and mostly useful when running a specific tests.
      Attempting to run larger chunks of the test suite experienced many issues:
      
      * Many tests depend on being able to start and control `redis-server` themselves,
      and there's no clear distinction between external server compatible and other
      tests.
      * Cluster mode is not supported (resulting with `CROSSSLOT` errors).
      
      This PR cleans up many things and makes it possible to run the entire test suite
      against an external server. It also provides more fine grained controls to
      handle cases where the external server supports a subset of the Redis commands,
      limited number of databases, cluster mode, etc.
      
      The tests directory now contains a `README.md` file that describes how this
      works.
      
      This commit also includes additional cleanups and fixes:
      
      * Tests can now be tagged.
      * Tag-based selection is now unified across `start_server`, `tags` and `test`.
      * More information is provided about skipped or ignored tests.
      * Repeated patterns in tests have been extracted to common procedures, both at a
        global level and on a per-test file basis.
      * Cleaned up some cases where test setup was based on a previous test executing
        (a major anti-pattern that repeats itself in many places).
      * Cleaned up some cases where test teardown was not part of a test (in the
        future we should have dedicated teardown code that executes even when tests
        fail).
      * Fixed some tests that were flaky running on external servers.
      8a86bca5