1. 01 Sep, 2020 17 commits
  2. 20 Jul, 2020 15 commits
    • WuYunlong's avatar
      Fix command help for unexpected options (#7476) · b1a01fda
      WuYunlong authored
      
      (cherry picked from commit 93bdbf5a)
      b1a01fda
    • Oran Agra's avatar
      redis-cli tests, fix valgrind timing issue (#7519) · 05f8975d
      Oran Agra authored
      this test when run with valgrind on github actions takes 160 seconds
      
      (cherry picked from commit 254c9625)
      05f8975d
    • WuYunlong's avatar
      Fix out of update help info in tcl tests. (#7516) · 4780cc5e
      WuYunlong authored
      Before this commit, the output of "./runtest-cluster --help" is incorrect.
      After this commit, the format of the following 3 output is consistent:
      ./runtest --help
      ./runtest-cluster --help
      ./runtest-sentinel --help
      
      (cherry picked from commit 8128d397)
      4780cc5e
    • Oran Agra's avatar
      fix recently added time sensitive tests failing with valgrind (#7512) · aea4db2f
      Oran Agra authored
      interestingly the latency monitor test fails because valgrind is slow
      enough so that the time inside PEXPIREAT command from the moment of
      the first mstime() call to get the basetime until checkAlreadyExpired
      calls mstime() again is more than 1ms, and that test was too sensitive.
      
      using this opportunity to speed up the test (unrelated to the failure)
      the fix is just the longer time passed to PEXPIRE.
      
      (cherry picked from commit e5227aab)
      aea4db2f
    • Oran Agra's avatar
      runtest --stop pause stops before terminating the redis server (#7513) · b5c5f870
      Oran Agra authored
      in the majority of the cases (on this rarely used feature) we want to
      stop and be able to connect to the shard with redis-cli.
      since these are two different processes interracting with the tty we
      need to stop both, and we'll have to hit enter twice, but it's not that
      bad considering it is rarely used.
      
      (cherry picked from commit 02ef355f)
      b5c5f870
    • WuYunlong's avatar
      Add missing latency-monitor tcl test to test_helper.tcl. (#6782) · f838df92
      WuYunlong authored
      
      (cherry picked from commit d792db79)
      f838df92
    • Yossi Gottlieb's avatar
      TLS: Session caching configuration support. (#7420) · 7a536c29
      Yossi Gottlieb authored
      * TLS: Session caching configuration support.
      * TLS: Remove redundant config initialization.
      
      (cherry picked from commit 3e6f2b1a)
      7a536c29
    • Yossi Gottlieb's avatar
      TLS: Add missing redis-cli options. (#7456) · b057ff81
      Yossi Gottlieb authored
      * Tests: fix and reintroduce redis-cli tests.
      
      These tests have been broken and disabled for 10 years now!
      
      * TLS: add remaining redis-cli support.
      
      This adds support for the redis-cli --pipe, --rdb and --replica options
      previously unsupported in --tls mode.
      
      * Fix writeConn().
      
      (cherry picked from commit d9f970d8)
      b057ff81
    • Oran Agra's avatar
      RESTORE ABSTTL won't store expired keys into the db (#7472) · 95ba01b5
      Oran Agra authored
      Similarly to EXPIREAT with TTL in the past, which implicitly deletes the
      key and return success, RESTORE should not store key that are already
      expired into the db.
      When used together with REPLACE it should emit a DEL to keyspace
      notification and replication stream.
      
      (cherry picked from commit 5977a948)
      95ba01b5
    • Oran Agra's avatar
      skip a test that uses +inf on valgrind (#7440) · 33ca884c
      Oran Agra authored
      On some platforms strtold("+inf") with valgrind returns a non-inf result
      
      [err]: INCRBYFLOAT does not allow NaN or Infinity in tests/unit/type/incr.tcl
      Expected 'ERR*would produce*' to equal or match '1189731495357231765085759.....'
      
      (cherry picked from commit 909bc97c)
      33ca884c
    • Oran Agra's avatar
      stabilize tests that look for log lines (#7367) · 2b5f2319
      Oran Agra authored
      tests were sensitive to additional log lines appearing in the log
      causing the search to come empty handed.
      
      instead of just looking for the n last log lines, capture the log lines
      before performing the action, and then search from that offset.
      
      (cherry picked from commit 8e76e134)
      2b5f2319
    • Oran Agra's avatar
      tests/valgrind: don't use debug restart (#7404) · 1104113c
      Oran Agra authored
      * tests/valgrind: don't use debug restart
      
      DEBUG REATART causes two issues:
      1. it uses execve which replaces the original process and valgrind doesn't
         have a chance to check for errors, so leaks go unreported.
      2. valgrind report invalid calls to close() which we're unable to resolve.
      
      So now the tests use restart_server mechanism in the tests, that terminates
      the old server and starts a new one, new PID, but same stdout, stderr.
      
      since the stderr can contain two or more valgrind report, it is not enough
      to just check for the absence of leaks, we also need to check for some known
      errors, we do both, and fail if we either find an error, or can't find a
      report saying there are no leaks.
      
      other changes:
      - when killing a server that was already terminated we check for leaks too.
      - adding DEBUG LEAK which was used to test it.
      - adding --trace-children to valgrind, although no longer needed.
      - since the stdout contains two or more runs, we need slightly different way
        of checking if the new process is up (explicitly looking for the new PID)
      - move the code that handles --wait-server to happen earlier (before
        watching the startup message in the log), and serve the restarted server too.
      
      * squashme - CR fixes
      
      (cherry picked from commit 69ade873)
      1104113c
    • antirez's avatar
      LPOS: option FIRST renamed RANK. · 17aaf5ec
      antirez authored
      (cherry picked from commit a5a3a7bb)
      17aaf5ec
    • Oran Agra's avatar
      EXEC always fails with EXECABORT and multi-state is cleared · 05e483cb
      Oran Agra authored
      In order to support the use of multi-exec in pipeline, it is important that
      MULTI and EXEC are never rejected and it is easy for the client to know if the
      connection is still in multi state.
      
      It was easy to make sure MULTI and DISCARD never fail (done by previous
      commits) since these only change the client state and don't do any actual
      change in the server, but EXEC is a different story.
      
      Since in the past, it was possible for clients to handle some EXEC errors and
      retry the EXEC, we now can't affort to return any error on EXEC other than
      EXECABORT, which now carries with it the real reason for the abort too.
      
      Other fixes in this commit:
      - Some checks that where performed at the time of queuing need to be re-
        validated when EXEC runs, for instance if the transaction contains writes
        commands, it needs to be aborted. there was one check that was already done
        in execCommand (-READONLY), but other checks where missing: -OOM, -MISCONF,
        -NOREPLICAS, -MASTERDOWN
      - When a command is rejected by processCommand it was rejected with addReply,
        which was not recognized as an error in case the bad command came from the
        master. this will enable to count or MONITOR these errors in the future.
      - make it easier for tests to create additional (non deferred) clients.
      - add tests for the fixes of this commit.
      
      (cherry picked from commit 65a3307b)
      05e483cb
    • meir@redislabs.com's avatar
      Fix RM_ScanKey module api not to return int encoded strings · 51e17845
      meir@redislabs.com authored
      The scan key module API provides the scan callback with the current
      field name and value (if it exists). Those arguments are RedisModuleString*
      which means it supposes to point to robj which is encoded as a string.
      Using createStringObjectFromLongLong function might return robj that
      points to an integer and so break a module that tries for example to
      use RedisModule_StringPtrLen on the given field/value.
      
      The PR introduces a fix that uses the createObject function and sdsfromlonglong function.
      Using those function promise that the field and value pass to the to the
      scan callback will be Strings.
      
      The PR also changes the Scan test module to use RedisModule_StringPtrLen
      to catch the issue. without this, the issue is hidden because
      RedisModule_ReplyWithString knows to handle integer encoding of the
      given robj (RedisModuleString).
      
      The PR also introduces a new test to verify the issue is solved.
      
      (cherry picked from commit a89bf734)
      51e17845
  3. 12 Jun, 2020 1 commit
  4. 09 Jun, 2020 2 commits
  5. 06 Jun, 2020 1 commit
  6. 28 May, 2020 4 commits
    • antirez's avatar
      Test: take PSYNC2 test master timeout high during switch. · 59cd4c9f
      antirez authored
      This will likely avoid false positives due to trailing pings.
      59cd4c9f
    • antirez's avatar
      Test: add the tracking unit as default. · 6c1bb7b1
      antirez authored
      6c1bb7b1
    • Oran Agra's avatar
      tests: find_available_port start search from next port · 1aee695e
      Oran Agra authored
      i.e. don't start the search from scratch hitting the used ones again.
      this will also reduce the likelihood of collisions (if there are any
      left) by increasing the time until we re-use a port we did use in the
      past.
      1aee695e
    • Oran Agra's avatar
      tests: each test client work on a distinct port range · a2ae4635
      Oran Agra authored
      apparently when running tests in parallel (the default of --clients 16),
      there's a chance for two tests to use the same port.
      specifically, one test might shutdown a master and still have the
      replica up, and then another test will re-use the port number of master
      for another master, and then that replica will connect to the master of
      the other test.
      
      this can cause a master to count too many full syncs and fail a test if
      we run the tests with --single integration/psync2 --loop --stop
      
      see Probmem 2 in #7314
      a2ae4635