500 Commits

Author SHA1 Message Date
antirez
95fe993018 ACL: Test: check subcommands (test fails). 2019-01-28 18:29:22 +01:00
antirez
7b1493a249 ACL: Test: nopass user flag, commands/groups +/- rules. 2019-01-28 12:40:07 +01:00
antirez
b03f0c0403 ACL: Test: check default behavior and keys ACLs. 2019-01-28 12:33:18 +01:00
antirez
c2865f4810 ACL: Test: check passwords validity and removal. 2019-01-28 12:06:25 +01:00
antirez
619017f9c2 ACL: Test: enabled/disabled user. 2019-01-28 11:44:10 +01:00
antirez
296f43b2dd ACL: create unit test. 2019-01-28 11:39:58 +01:00
antirez
f1e57a86f9 ACL: implement resetpass directive and adjust test. 2019-01-18 11:26:32 +01:00
antirez
7e73a1fbf3 ACL: AUTH + no default user password raises an error.
This way the behavior is very similar to the past one.
This is useful in order to remember the user she probably failed to
configure a password correctly.
2019-01-17 18:30:23 +01:00
Salvatore Sanfilippo
4808a09a4f Merge pull request #5549 from oranagra/fix_test_races
fix small test suite race conditions
2018-11-28 18:17:05 +01:00
antirez
2d5544de8b Merge branch 'unstable' of github.com:/antirez/redis into unstable 2018-11-28 17:12:32 +01:00
Qu Chen
eb1c67673d Add unit test for stream XCLAIM command. 2018-11-28 17:12:03 +01:00
Salvatore Sanfilippo
8981b91c2f Merge pull request #4737 from guybe7/zlexcount_fix
Don't call sdscmp() with shared.maxstring or shared.minstring
2018-11-28 16:53:32 +01:00
antirez
41615d418b Test: regression test for #5570. 2018-11-19 17:19:33 +01:00
antirez
0d7f49c3cc Test: regression test for #5577. 2018-11-19 16:50:54 +01:00
Oran Agra
77400dde8a fix small test suite race conditions 2018-11-12 10:26:10 +02:00
antirez
3d12201501 Tests for XGROUP CREATE MKSTREAM. 2018-10-17 12:11:10 +02:00
zhaozhao.zz
1e925aeb75 Streams: Tests modified XSTREAM -> XSETID 2018-10-16 23:56:26 +08:00
antirez
62bbb6b12e Tests modified to use XADD MAXLEN 0 + XSETID.
See #5426.
2018-10-16 17:28:56 +02:00
Salvatore Sanfilippo
060cd5c941 Merge pull request #5426 from soloestoy/feature-xstream
Bugfix data inconsistency after aof rewrite, and add XSTREAM command.
2018-10-16 13:10:36 +02:00
antirez
ff963fade8 Test: avoid time related false positive in RESTORE test. 2018-10-13 14:17:11 +02:00
antirez
de45608faa Test: cgroup propagation test also for NOACK variant.
Related to #5433.
2018-10-10 17:37:41 +02:00
antirez
f28775a5b5 Test: consumer group last ID slave propagation test.
This is a regression for #5433.
2018-10-10 17:32:17 +02:00
zhaozhao.zz
9a034cd5f6 Streams: add tests for aof rewrite 2018-10-09 15:45:58 +08:00
zhaozhao.zz
b4d448baa9 Streams: add tests for XSTREAM command 2018-10-09 15:21:08 +08:00
Salvatore Sanfilippo
f654899b7f Merge pull request #5141 from soloestoy/fix-xtrim-inconsistency
Fix XTRIM and XADD with MAXLEN inconsistency
2018-10-08 12:00:00 +02:00
Oran Agra
e531447d6c fix #5024 - commandstats for multi-exec were logged as EXEC.
this was broken a while back by ba9154d7e7bf959b002533384319a1e90545447b
the purpose of which was to fix commandstats for GEOADD
2018-09-30 12:43:11 +03:00
antirez
edaed47358 Slave removal: remove slave from top-level tests descriptions. 2018-09-11 15:32:28 +02:00
antirez
90504c0387 Fix scripting tests now that we default to commands repl. 2018-09-05 19:54:54 +02:00
Salvatore Sanfilippo
aeb2ee7ffe Merge pull request #5265 from oranagra/stabilize_tests
Fix unstable tests on slow machines.
2018-08-27 13:19:31 +02:00
Oran Agra
7723c36577 Fix unstable tests on slow machines.
Few tests had borderline thresholds that were adjusted.

The slave buffers test had two issues, preventing the slave buffer from growing:
1) the slave didn't necessarily go to sleep on time, or woke up too early,
   now using SIGSTOP to make sure it goes to sleep exactly when we want.
2) the master disconnected the slave on timeout
2018-08-21 11:46:07 +03:00
zhaozhao.zz
1c84c4431f adjust qbuf to 26 in test case for client list 2018-08-14 00:57:22 +08:00
antirez
f2d987a63d Test: new sorted set skiplist order consistency.
This should be able to find new bugs and regressions about the new
sorted set update function when ZADD is used to update an element
already existing.

The test is able to find the bug fixed at 2f282aee immediately.
2018-08-02 14:15:53 +02:00
zhaozhao.zz
fedb5c6353 Streams: add test cases for XADD/XTRIM maxlen 2018-08-01 10:34:29 +08:00
Oran Agra
c5058ebee1 fix slave buffer test suite false positives
it looks like on slow machines we're getting:
[err]: slave buffer are counted correctly in tests/unit/maxmemory.tcl
Expected condition '$slave_buf > 2*1024*1024' to be true (16914 > 2*1024*1024)

this is a result of the slave waking up too early and eating the
slave buffer before the traffic and the test ends.
2018-07-24 11:24:27 +03:00
Oran Agra
0a4d1f114e make active defrag test more stable
on slower machines, the active defrag test tended to fail.
although the fragmentation ratio was below the treshold, the defragger was
still in the middle of a scan cycle.

this commit changes:
- the defragger uses the current fragmentation state, rather than the cache one
  that is updated by server cron every 100ms. this actually fixes a bug of
  starting one excess scan cycle
- the test lets the defragger use more CPU cycles, in hope that the defrag
  will be faster, but also give it more time before we give up.
2018-07-18 10:16:33 +03:00
Oran Agra
1f2ed12d07 slave buffers were wasteful and incorrectly counted causing eviction
A) slave buffers didn't count internal fragmentation and sds unused space,
   this caused them to induce eviction although we didn't mean for it.

B) slave buffers were consuming about twice the memory of what they actually needed.
- this was mainly due to sdsMakeRoomFor growing to twice as much as needed each time
  but networking.c not storing more than 16k (partially fixed recently in 237a38737).
- besides it wasn't able to store half of the new string into one buffer and the
  other half into the next (so the above mentioned fix helped mainly for small items).
- lastly, the sds buffers had up to 30% internal fragmentation that was wasted,
  consumed but not used.

C) inefficient performance due to starting from a small string and reallocing many times.

what i changed:
- creating dedicated buffers for reply list, counting their size with zmalloc_size
- when creating a new reply node from, preallocate it to at least 16k.
- when appending a new reply to the buffer, first fill all the unused space of the
  previous node before starting a new one.

other changes:
- expose mem_not_counted_for_evict info field for the benefit of the test suite
- add a test to make sure slave buffers are counted correctly and that they don't cause eviction
2018-07-16 16:43:42 +03:00
antirez
4b8c53d243 Test: XDEL fuzz testing. Remove and check stage. 2018-07-13 17:58:17 +02:00
antirez
9d5178360d Test: XDEL fuzz testing, stream creation. 2018-07-13 17:47:26 +02:00
antirez
b25238baa9 Merge branch 'unstable' of github.com:/antirez/redis into unstable 2018-07-13 17:41:10 +02:00
antirez
de5d4dbed6 Test: XDEL basic test. 2018-07-13 17:40:48 +02:00
WuYunlong
89e8472e0f Add test in slowlog.tcl 2018-07-13 17:51:06 +08:00
antirez
fe41bc4ab1 Add regression test for #5111. 2018-07-12 13:35:17 +02:00
Jack Drogon
df7bafeb44 Fix typo 2018-07-03 18:19:46 +02:00
chendianqiang
0a32c93dd5 Merge branch 'unstable' into pending-querybuf 2018-07-03 10:07:26 +08:00
chendianqiang
2dc66b6bcc limit the size of pending-querybuf in masterclient 2018-07-01 14:43:53 +08:00
Oran Agra
9df4b2b9b4 minor fix in creating a stream NACK for rdb and defrag tests 2018-06-27 15:34:17 +03:00
Oran Agra
cfa076f2ee add active defrag support for streams 2018-06-27 15:00:41 +03:00
shenlongxing
bdb2664a81 fix typo 2018-06-21 22:08:09 +08:00
Guy Benoish
56163a78a4 Enhance RESTORE with RDBv9 new features
RESTORE now supports:
1. Setting LRU/LFU
2. Absolute-time TTL

Other related changes:
1. RDB loading will not override LRU bits when RDB file
   does not contain the LRU opcode.
2. RDB loading will not set LRU/LFU bits if the server's
   maxmemory-policy does not match.
2018-06-20 15:11:08 +07:00
antirez
5bcfe3dc38 Fix SCAN bug regression test, avoiding empty SREM call. 2018-06-14 12:21:58 +02:00