1
0
Fork 0
mirror of https://github.com/dragonflydb/dragonfly.git synced 2024-12-14 11:58:02 +00:00
Commit graph

318 commits

Author SHA1 Message Date
ashotland
f628131b9e
fix(tests):Small fix to redis replication test (#1213)
Move timeout decrement to the end so we don't assert if we succeed in
the last second (looks like this was the case in the recent regression
test failure on CI)

Clarify the comment of await_synced

Signed-off-by: ashotland <ari@dragonflydb.io>
2023-05-14 01:08:17 +03:00
Vladislav
eec09a13c7
fix: fix test connection name (#1211)
Signed-off-by: Vladislav Oleshko <vlad@dragonflydb.io>
2023-05-13 15:25:36 +02:00
Vladislav
396cf5f77b
fix: fix duplicated dependency (#1209)
Signed-off-by: Vladislav Oleshko <vlad@dragonflydb.io>
2023-05-13 12:07:54 +02:00
Vladislav
b0537418bc
fix: use redis.asyncio instead of aioredis (#1206)
Signed-off-by: Vladislav Oleshko <vlad@dragonflydb.io>
2023-05-13 10:44:25 +03:00
Roy Jacobson
300ccf3218
fix(server): Wrong replication state (#1150)
* fix(server): Read replication state better

* Add basic test for ROLE command and replication
2023-04-30 14:02:47 +03:00
ashotland
6a26d41e90
test(sentinel_test.py): increase timeout in failover test (#1133)
* test(sentinel_test.py): increase timeout from 10 to 15 seconds in test_failover function

Signed-off-by: ashotland <ari@dragonflydb.io>

---------

Signed-off-by: ashotland <ari@dragonflydb.io>
2023-04-24 21:55:11 +03:00
ashotland
6fcd15d1e1
Sentinel test debug (#1125)
Sentinal test debug
- Some more logging
- Use PortPicker

Signed-off-by: ashotland <ari@dragonflydb.io>
2023-04-24 10:53:51 +03:00
adiholden
7f56a435c4
bug(server): replicate scripts in stable state (#1114)
* bug(server): replicate scripts in stable state

---------

Signed-off-by: adi_holden <adi@dragonflydb.io>
2023-04-23 23:46:51 +03:00
Vladislav
2d501111ea
Fix async lua bugs (#1123)
Fix async lua bugs:
- Not calling toupper before looking up command id
- Wrong error reply context
2023-04-23 14:50:25 +03:00
adiholden
c6d34678f3
fix(test): add wait for all replicas to finish (#1124)
Signed-off-by: adi_holden <adi@dragonflydb.io>
2023-04-23 14:20:01 +03:00
Vladislav
74a1454409
Collect errors from async lua calls (#1092)
Error collection from async calls
2023-04-22 09:02:22 +03:00
Roy Jacobson
46a2435865
fix(tests): Disable 'dbfilename' unless explicitly given in the test (#1117) 2023-04-20 13:11:49 +03:00
Roy Jacobson
246f6093db
feat(server): Save on shutdown (#1086)
* feat(server): Save snapshot on shutdown

* CR

* Change save on shutdown to be conditional on --dbfilename.

* Support SHUTDOWN [NO]SAVE and fix unit test

* Better wait for DB loading

* Fix DF format loading state bug

* Fix some fallout from auto save
2023-04-20 06:30:42 +02:00
Roy Jacobson
1319918476
fix(server): Don't allow directory escapes in dbfilename (#1105)
* fix(server): Don't allow directory escapes in dbfilename

* Just disallow directories completely
2023-04-18 21:21:23 -07:00
Vladislav
77e18f0463
fix: report errors from commands with redis.call (#1108)
Redis call now directly reports erros
2023-04-18 17:29:07 +03:00
Roy Jacobson
1382ed1c37
chore: Allow passing empty strings as flag arguments in DflyInstance (#1104)
For example, this is needed to disable auto save on shutdown with --dbfilename=""
2023-04-18 12:48:30 +03:00
Roy Jacobson
d9f45f369a
fix(server): Allow interrupting REPLICAOF commands during full sync (#1058)
* fix(server): Allow interrupting REPLICAOF commands during full sync
* fix(server): Fix a race condition and UB in a debug assert
2023-04-18 11:44:44 +03:00
Vladislav
0e7d137046
fix: fix default instance port blocking in pytest (#1102)
Signed-off-by: Vladislav Oleshko <vlad@dragonflydb.io>
2023-04-18 00:12:38 +03:00
Roy Jacobson
c952251381
feat(server): Insert timestamp into snapshot names explicitly (#1028)
* feat(server): Insert timestamp into snapshot names explicitly

* Whenever the snapshot filename contains '{timestamp}', it will be substituted with the current local time.
* Default snapshot name is now "dump-{timestamp}"
* InferLoadFile: Modify to recognize "{timestamp}" files correctly.
* ServerFamily::Load: Change extension 'CHECK' into a non-terminating error because it's user-visible
* ServerFamily::DoSave: Add sanity check for the filename extension.

Signed-off-by: Roy Jacobson <roy@dragonflydb.io>

* resolve CR comments

* Add comment about glob sorted output

* Fix InferLoadFile and fix its tests

* Simplify filename behavior with the .dfs format

---------

Signed-off-by: Roy Jacobson <roy@dragonflydb.io>
2023-04-17 14:59:44 +03:00
Roy Jacobson
fc66dbb2cf
fix(tests): Don't return the same port from PortPicker.get_available_port twice (#1083) 2023-04-13 09:56:46 +03:00
Vladislav
282c168d34
fix: Update cntx->cid on multi-tx'es (#1081)
Signed-off-by: Vladislav Oleshko <vlad@dragonflydb.io>
2023-04-12 23:28:31 +03:00
ashotland
5fb5f54885
fix(regression-tests): Add PortPicker (#1078)
* fix(regression-tests): Add PortManager

Add PortManager to find and use available ports in regression tests.
Use it in redis_replicaiton_test.
---------

Signed-off-by: ashotland <ari@dragonflydb.io>
2023-04-12 19:14:29 +03:00
ashotland
59f1ac6701
fix(regression-test): Delete tests/dump.rdb (#1077)
fix(regression-test): Delete dump.rdb

This fails redis to start in redis_replicaiton_test,
I assume it was added accidently.

Signed-off-by: ashotland <ari@dragonflydb.io>
2023-04-12 14:13:39 +03:00
Vladislav
c774aee6fb
fix: fix lua monitor pytest (#1073)
Signed-off-by: Vladislav Oleshko <vlad@dragonflydb.io>
2023-04-11 23:01:34 +03:00
Vladislav
a4305fe2e2
feat(tests): rand seed flag and output (#1044)
Signed-off-by: Vladislav Oleshko <vlad@dragonflydb.io>
2023-04-05 16:22:47 +03:00
adiholden
0312b66244
bug(replication): fix deadlock in cancle replication flow (#1007)
Signed-off-by: adi_holden <adi@dragonflydb.io>
2023-03-29 12:11:56 +03:00
dependabot[bot]
6a8584b4d6
chore(deps): bump redis from 4.3.4 to 4.5.3 in /tests/dragonfly (#1005)
Bumps [redis](https://github.com/redis/redis-py) from 4.3.4 to 4.5.3.
- [Release notes](https://github.com/redis/redis-py/releases)
- [Changelog](https://github.com/redis/redis-py/blob/master/CHANGES)
- [Commits](https://github.com/redis/redis-py/compare/v4.3.4...v4.5.3)

---
updated-dependencies:
- dependency-name: redis
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-03-28 17:27:11 +03:00
adiholden
89da9a99d0
bug(replica): support auth master (#1000)
* bug(replica): support auth master

Signed-off-by: adi_holden <adi@dragonflydb.io>
2023-03-28 12:17:53 +03:00
Roman Gershman
32f2f4b72a
fix: list_family_test works with async client (#992) 2023-03-25 21:28:29 +03:00
Roman Gershman
3939da1069
fix: Adapt json_test to async_client (#990) 2023-03-25 16:05:30 +03:00
Chaka
7be98d906d
bug(server): Fix crash in ZPOPMIN (#977)
* Fix crash in ZPOPMIN

Crash was due to an attempt to access nullptr[-1], which is bad :)

* Add test to repro crash.

There's some leftover debugging statements, they're somewhat useful so I
kept them as the bug is not yet fixed.

* Copy patch by romange to solve the crash

Also re-enable (uncomment) the test in utility.py.

Signed-off-by: chakaz <chakaz@chakaz>

---------

Signed-off-by: chakaz <chakaz@chakaz>
Signed-off-by: Chaka <chakaz@users.noreply.github.com>
Co-authored-by: chakaz <chakaz@chakaz>
2023-03-25 10:05:41 +03:00
Roman Gershman
52ac06e358
chore: Improve client connection checking in pytests (#967)
Also fix the compatibility of "client list" with redis-py client.

Signed-off-by: Roman Gershman <roman@dragonflydb.io>
2023-03-24 18:22:14 +03:00
Vladislav
3a6b98f201
fix(pytest): Disable script test (#972) 2023-03-21 16:53:47 +03:00
ashotland
85a1bf8494
fix(tests):Comment out ZPOPMIN Action Again (#971)
fix(tests):Comment out SPOPMIN Action Again 

Until #949 is fixed

Signed-off-by: ashotland <ari@dragonflydb.io>
2023-03-21 15:26:46 +02:00
Vladislav
6d3a191a5f
tests(replication): Test script replication (#960)
Script replication test
2023-03-20 22:57:52 +03:00
ashotland
d2d70289ff
fix(tests): Revive commented out actions (#962)
* fix(tests): Revive commented out actions
---------

Signed-off-by: ashotland <ari@dragonflydb.io>
2023-03-19 22:30:50 +02:00
Roman Gershman
c96f637f73 chore: some pytests and logging improvements
1. pytest extensions and fixes - allows running them
   with the existing local server by providing its port (--existing <port>).
2. Extend "DEBUG WATCHED" command to provide more information about watched state.
3. Improve debug/vlog printings around the code.

This noisy PR is a preparation before BRPOP fix that will follow later.

Signed-off-by: Roman Gershman <roman@dragonflydb.io>
2023-03-17 10:52:20 +02:00
Pascal S. de Kloe
f9ec60ee5f integration test docker image with Go client 2023-03-17 10:09:42 +02:00
adiholden
bafad66fc3
fix(replication): redis replication flush all before full sync (#946)
Signed-off-by: adi_holden <adi@dragonflydb.io>
2023-03-15 09:45:04 +02:00
Roman Gershman
66b4fbd14e fix: correctly set batching mode during pubsub
Previously we set batch mode when dispatch queue is not empty
but dispatch queue could contain other async messages related to pubsub or monitor.
Now we enable batching only if there are more pipeline commands in the queue.

In addition, fix the issue of unlimited aggregation of batching buffer.

Fixes #935.

Signed-off-by: Roman Gershman <roman@dragonflydb.io>
2023-03-14 13:01:48 +02:00
adiholden
97e38aebd2
bug(redis replication): fix multi transaction replication stable state (#934)
Signed-off-by: adi_holden <adi@dragonflydb.io>
2023-03-13 15:14:58 +02:00
adiholden
8e528f1fbb
fix(redis_replicaiton_test): fix compare set types (#929)
* fix(redis_replicaiton_test): fix compare set types

Signed-off-by: ashotland <ari@dragonflydb.io>
Co-authored-by: ashotland <ari@dragonflydb.io>
2023-03-13 13:37:58 +02:00
Roman Gershman
7975848c36 chore: Expose a corruption when connection writes interleaving messages
The problem happens when a publisher sends a message and a new subscriber registers.
In that case it sends "subscribe" response and the publish messages and those
interleave sometimes.

Signed-off-by: Roman Gershman <roman@dragonflydb.io>
2023-03-12 08:15:31 +02:00
ashotland
02770fdcd1
fix(tests):Some test cases for redis replication (#918)
* Some test cases for redis replication

Most of them skipped / commented-out to serve as repro without failing
on CI.

---------

Signed-off-by: ashotland <ari@dragonflydb.io>
2023-03-08 10:22:58 +02:00
Vladislav
7cb2232edc
fix(pytest): Add master restart delay (#909)
- Add restart delay to master in crashing master test
- Add process check after force shutdown
- Increase time limit to 45 min
2023-03-06 00:16:57 +03:00
talbii
0196589786
fix: logging in sentinel_test (#869)
Signed-off-by: talbii <ido@dragonflydb.io>
2023-03-05 16:15:13 +02:00
ashotland
ccc784d9c4
Add basic replicaiton from redis test (#895)
Signed-off-by: ashotland <ari@dragonflydb.io>
2023-03-01 21:50:51 +02:00
Roman Gershman
ac280529cb
fix: resize buffer correctly when checking for http header line (#894)
* fix: resize buffer correctly when checking for http header line

Fixes #779

Signed-off-by: Roman Gershman <roman@dragonflydb.io>

* fix(tests): Add big command test

Signed-off-by: Vladislav Oleshko <vlad@dragonflydb.io>

---------

Signed-off-by: Roman Gershman <roman@dragonflydb.io>
Signed-off-by: Vladislav Oleshko <vlad@dragonflydb.io>
Co-authored-by: Vladislav Oleshko <vlad@dragonflydb.io>
2023-03-01 21:46:45 +02:00
Vladislav
edbd43a3b3
Support script configuration (#889)
Store script parameters for each script that allow configuring it's transactions multi mode. They can be configured either for a specific scripts with `SCRIPT CONIFG <sha> [params...]` or changed globally as defaults with `default_lua_config`.
The current supported options are `allow-undeclared-keys` and `disable-atomicity`.  Based on those flags, we determine the correct multi mode. `disable-atomicity` allow running in non-atomic mode, whereas being atomic and enabling `allow-undeclared-keys` requires the global mode.
2023-03-01 19:17:41 +03:00
Leonardo Mello
abe3b3cb91
feat: support cluster mode emulation (#492)
Signed-off-by: Leonardo Mello <lsvmello@gmail.com>
2023-03-01 08:43:40 +02:00
Vladislav
90233bfdc8
feat(tests): Script pytests (#872)
Introduce pytests for eval
2023-02-25 13:06:05 +03:00
Vladislav
afa750303e
feat(tests): Add rotating master test (#828) 2023-02-20 18:18:10 +03:00
ashotland
1f82f9af73
fix(regression-test): Sentinel test stabilization (#826)
* Ditch docker whcih is complex on CI in favour of local redis binary

Signed-off-by: ashotland <ari@dragonflydb.io>

* Fix typo

Signed-off-by: ashotland <ari@dragonflydb.io>

* Wait for sentinel termination

Signed-off-by: ashotland <ari@dragonflydb.io>

* fix(regression-tests): sentinel test increase timeout waiting for key to
exist in replica

* debug sentinel test

Signed-off-by: ashotland <ari@dragonflydb.io>

* add pytest repeat - tmp comment out failure notficicaiton

Signed-off-by: ashotland <ari@dragonflydb.io>

* fix typo

Signed-off-by: ashotland <ari@dragonflydb.io>

* repeat 100

Signed-off-by: ashotland <ari@dragonflydb.io>

* Increase timeout for debuging

Signed-off-by: ashotland <ari@dragonflydb.io>

* Debug prints

Signed-off-by: ashotland <ari@dragonflydb.io>

* fix

Signed-off-by: ashotland <ari@dragonflydb.io>

* increase overall timeout

Signed-off-by: ashotland <ari@dragonflydb.io>

* Debug

Signed-off-by: ashotland <ari@dragonflydb.io>

* cleanup

Signed-off-by: ashotland <ari@dragonflydb.io>

---------

Signed-off-by: ashotland <ari@dragonflydb.io>
2023-02-20 14:21:27 +02:00
ashotland
4b3dc87ba0
Fix(regression-tests): Sentinel test - wait for sentinel termination (#816)
* Ditch docker whcih is complex on CI in favour of local redis binary

Signed-off-by: ashotland <ari@dragonflydb.io>

* Fix typo

Signed-off-by: ashotland <ari@dragonflydb.io>

* Wait for sentinel termination

Signed-off-by: ashotland <ari@dragonflydb.io>

---------

Signed-off-by: ashotland <ari@dragonflydb.io>
2023-02-17 16:45:39 +02:00
Vladislav
83256bd4e1
fix(pytest): fix periodic test (#804)
Signed-off-by: Vladislav Oleshko <vlad@dragonflydb.io>
2023-02-15 11:12:41 +02:00
Vladislav
6dedb33f85
fix(pytest): SAVE to SAVE RDB (#803) 2023-02-15 11:15:38 +03:00
adiholden
50f50c8380
feat(server): write journal record with optional await based on flag… (#791)
* feat(server): write journal recorod with optional await based on flag issue #788

Signed-off-by: adi_holden <adi@dragonflydb.io>
2023-02-15 09:34:24 +02:00
ashotland
49b1ba5b6d
feat(server): Enable overriding --requirepass form env var (#792)
Signed-off-by: ashotland <ari@dragonflydb.io>
2023-02-14 13:19:33 +02:00
Vladislav
25db011afc
fix(server): Fix bugs (#797) 2023-02-14 13:42:20 +03:00
adiholden
ee2807c9bc
feat(replica): add debug command - replica offset (#786)
* feat(replica): add debug command - replica offset

Signed-off-by: adi_holden <adi@dragonflydb.io>
2023-02-13 13:00:46 +02:00
Boaz Sade
e7a5d583d0
fix(server): monitor lua at script execution (#767)
Signed-off-by: Boaz Sade <boaz@dragonflydb.io>
2023-02-12 18:22:40 +02:00
adiholden
41c1ebab18
bug(replica): execute expire within multi command only if its belong … (#766)
Signed-off-by: adi_holden <adi@dragonflydb.io>
2023-02-08 14:33:05 +02:00
adiholden
cc74594c2f
bug(replication): BLPOP fix write to shard journal of popped key (#761)
Signed-off-by: adi_holden <adi@dragonflydb.io>
2023-02-06 10:04:48 +02:00
adiholden
69bca570f0
bug(server): fix deadlock in BufferedStreamerBase notify all producers (#760)
Signed-off-by: adi_holden <adi@dragonflydb.io>
2023-02-06 10:04:22 +02:00
ashotland
aef8631ab2
fix(regression-tests): sentinel_test.py: Ditch docker whcih is complex on CI in favour of local redis binary (#755)
* Ditch docker whcih is complex on CI in favour of local redis binary

Signed-off-by: ashotland <ari@dragonflydb.io>

* Fix typo

Signed-off-by: ashotland <ari@dragonflydb.io>

---------

Signed-off-by: ashotland <ari@dragonflydb.io>
2023-02-05 11:58:09 +02:00
adiholden
d30ebc5b0d
feat(server): replication should not evict items (#743)
Signed-off-by: adi_holden <adi@dragonflydb.io>
2023-02-05 09:04:08 +02:00
Vladislav
3449ba8a7b
Exclude single threaded test now that expiry is tested (#750) 2023-02-03 23:08:29 +03:00
ashotland
622013a2d1
fix(regression-tests):Skip sentinel regression tests (#748)
Skip sentinel regression tests

Signed-off-by: ashotland <ari@dragonflydb.io>
2023-02-02 18:16:31 +03:00
adiholden
4b29dece0c
test(replication test): check data only after replica finished execution (#746)
Signed-off-by: adi_holden <adi@dragonflydb.io>
2023-02-02 15:08:44 +02:00
adiholden
69519b2c5b
feat(list family): support blocking command for replication (#740) 2023-02-02 08:58:06 +02:00
ashotland
1e548673fa
fix(sentinel_test):Remove return type which breaks regression tests (#736)
Remove return type which breaks regression tests

Signed-off-by: ashotland <ari@dragonflydb.io>
2023-01-31 18:12:00 +02:00
Vladislav
4c9b30ca43
feat(server): Auto expiry + small replica refactor (#718) 2023-01-31 12:55:52 +03:00
adiholden
5c7ca77a72
test(replication test): increase sleep time in full sync step (#733)
Signed-off-by: adi_holden <adi@dragonflydb.io>
2023-01-30 09:45:18 +02:00
ashotland
29d47cdd1a
chore(tests): Sentinel test PR code review followup (#731)
* feat(server): Allow admin commands in multi

Needed for sentinel support (#706)

Signed-off-by: ashotland <ari@dragonflydb.io>

* feat(server): Add test coverage for multi global commands

Signed-off-by: ashotland <ari@dragonflydb.io>

* code review fixes

Signed-off-by: ashotland <ari@dragonflydb.io>

* Sentinel integration test

Signed-off-by: ashotland <ari@dragonflydb.io>

* PR code reiew follow up
Have lambda return awaitable instead of defining neoff async function

Signed-off-by: ashotland <ari@dragonflydb.io>

---------

Signed-off-by: ashotland <ari@dragonflydb.io>
2023-01-30 09:27:22 +02:00
ashotland
b00e83e3cc
feat(test): Sentinel Integration Test (#728)
* feat(server): Allow admin commands in multi

Needed for sentinel support (#706)

Signed-off-by: ashotland <ari@dragonflydb.io>

* feat(server): Add test coverage for multi global commands

Signed-off-by: ashotland <ari@dragonflydb.io>

* code review fixes

Signed-off-by: ashotland <ari@dragonflydb.io>

* Sentinel integration test

Signed-off-by: ashotland <ari@dragonflydb.io>

---------

Signed-off-by: ashotland <ari@dragonflydb.io>
2023-01-29 08:42:09 +02:00
adiholden
d660787c6b
test(replica): test journal rewrite with multi shards (#720)
Signed-off-by: adi_holden <adi@dragonflydb.io>
2023-01-24 14:31:25 +02:00
Vladislav
45162b5c0a
feat(server): Journal rewrite p2 + tests (#699) 2023-01-19 13:55:50 +03:00
Vladislav
1eb227e318
feat(server): Rewrite journal commands (basic) (#651) 2023-01-16 14:52:46 +03:00
adiholden
cee7a9e67d
test(replication_test) : add replica flushall test (#669)
Signed-off-by: adi_holden <adi@dragonflydb.io>
2023-01-15 09:28:30 +02:00
Vladislav
4d97918c7b
fix(server): Fix replication on a single thread (#676)
Signed-off-by: Vladislav Oleshko <vlad@dragonflydb.io>
2023-01-15 08:02:30 +02:00
Vladislav
861d12cdf5
fix(tests): Small pytest fixes (#673) 2023-01-14 23:49:24 +03:00
Vladislav
dd218fa037
feat(server): Json rdb support (#674) 2023-01-14 14:53:43 +03:00
adiholden
50e14db6c7
bug(snapshot): on journal write entry with opcode COMMAND and MULTI_C… (#662)
Signed-off-by: adi_holden <adi@dragonflydb.io>
2023-01-12 13:38:05 +02:00
Vladislav
5ef8454aa7
Pytests overhaul (#569) 2023-01-09 23:31:15 +03:00
Vladislav
7788600c9b
feat(server): Buffered journal serializers (#619) 2022-12-30 16:18:37 +03:00
Vladislav
e6721d8160
feat(server): Improved cancellation (#599) 2022-12-27 16:01:54 +03:00
Boaz Sade
3d610ee2d7
feat(server): JSON family using JSON type (#561)
feat(server): json family using json type

Signed-off-by: Boaz Sade <boaz@dragonflydb.io>

Signed-off-by: Boaz Sade <boaz@dragonflydb.io>
2022-12-14 19:25:10 +02:00
Vladislav
f98d6f3357
feat(server): Implement robust error & cancellation on replica (#531) 2022-12-11 12:11:25 +03:00
Vladislav
2493434b23
fix(server): Fix replication bug, add gdb opt to pytest (#513)
fix(server): Fix small bugs, add gdb opt to pytest

Signed-off-by: Vladislav Oleshko <vlad@dragonflydb.io>
2022-11-28 16:28:14 +02:00
Vladislav
39a231dde8
fix(server): Increase common abstraction usage (#511)
fix(server): Small fixes everywhere

Signed-off-by: Vladislav Oleshko <vlad@dragonflydb.io>
2022-11-22 20:19:48 +02:00
Vladislav
893c741c14
feat(server): Replication errors & cancellation (#501) 2022-11-22 19:17:31 +03:00
Boaz Sade
235ff67e44
fix(server): all scan commands needs to return cursor as bulk string #503 (#504)
fix(server): scan cursor returning bulk string #503

Signed-off-by: Boaz Sade <boaz@dragonflydb.io>
2022-11-21 20:18:38 +02:00
Vladislav
96c9332297
feat(server): Switch to stable state replication (#473)
* feat(server): Switch to stable state replication

Signed-off-by: Vladislav Oleshko <vlad@dragonflydb.io>
2022-11-17 20:41:33 +02:00
Boaz Sade
6f45e80137
fix(test): skip pytest test_simple_full_sync_mutli_crash due to crash (#497)
Signed-off-by: Boaz Sade <boaz@dragonflydb.io>

Signed-off-by: Boaz Sade <boaz@dragonflydb.io>
2022-11-16 14:05:33 +02:00
adiholden
b395834060
feat(server family): add connection set name command fixes #458 (#485)
server family: add connection set name command fixes #458

Signed-off-by: adi_holden <adi@dragonflydb.io>
2022-11-13 17:54:37 +02:00
Boaz Sade
214c10f165
fix(server): reject eval inside transaction multi blocks #457 (#471)
fix(server): block running lua script inside pipeline #457

Signed-off-by: Boaz Sade <boaz@dragonflydb.io>
2022-11-09 19:18:28 +02:00
Boaz Sade
5e64ed1fe3
feat(server): simplify handling of the pub message handling (#465)
feat(server): sending message to subscriber using shared ptr to simplify code

Signed-off-by: Boaz Sade <boaz@dragonflydb.io>
2022-11-08 15:04:31 +02:00
Vladislav
8424f74bec
feat(server): Basic capped full sync (#440)
Signed-off-by: Vladislav Oleshko <vlad@dragonflydb.io>
2022-11-06 17:27:43 +03:00
Boaz Sade
2ed4d3489b
feat(tests): ioredis being able to successfully run tests, make it ready to be part of CI (#459)
Signed-off-by: Boaz Sade <boaz@dragonflydb.io>
2022-11-06 15:21:41 +02:00
Vladislav
072cb2e8d9
refactor(tests): Refactor pytest (#449)
Signed-off-by: Vladislav Oleshko <vlad@dragonflydb.io>
2022-10-31 16:39:20 +02:00
Boaz Sade
e0559afb51
feat(server): monitor command - cover by tests (#435)
feat(server): pytests for monitor, pipeline and pubsub, update readme

Signed-off-by: Boaz Sade <boaz@dragonflydb.io>
2022-10-26 14:12:49 +03:00
Vladislav
e4357e1f10
feat(server): Multi rdb load (#430)
* feat(server): Multi rdb load

Signed-off-by: Vladislav Oleshko <vlad@dragonflydb.io>
2022-10-24 21:22:43 +03:00
Guilherme Gervasio
ce964f103a
chore(tests): adds support for ioredis integration tests + instructio… (#394)
chore(tests): adds support for ioredis integration tests + instructions in docs

Signed-off-by: Guilherme <gilairmay@gmail.com>
2022-10-17 10:15:53 +03:00
Vladislav
add252c301
fix(server): Fix QUIT not shutting down connection (#280)
* fix(server): Fix QUIT not shutting down connection

Fixes #170
2022-09-13 05:25:46 +03:00
Braydn
b7f85e59a6
feat(server): Implemented periodic snapshotting (#161) (#250)
* feat(server): Implemented periodic snapshotting (#161)

* feat(test): Added the ability to specify dragonfly cli parameters on a test basis (#199)

Signed-off-by: Braydn <braydn.moore@uwaterloo.ca>

* feat(server): Implemented periodic snapshotting (#161)

Code cleanup & CONTRIBUTORS.md modifcation

Signed-off-by: Braydn <braydn.moore@uwaterloo.ca>

* feat(server): Implemented periodic snapshotting (#161)

Parsing and race condition fixes. Improved pytests

Signed-off-by: Braydn <braydn.moore@uwaterloo.ca>

* feat(test): Cleaned up pytest code & added documentation (#199)

- Moved tests into their own file
- Renamed test namespace to avoid naming conflicts with pytest
- Updated requirements.txt to make test environment reproducible
- Added documentation to write tests

feat(server): Updated helio submodule

Signed-off-by: Braydn <braydn.moore@uwaterloo.ca>

Signed-off-by: Braydn <braydn.moore@uwaterloo.ca>
Co-authored-by: Braydn <braydnmoore3@gmail.com>
2022-08-26 13:54:38 +03:00
Roman Gershman
9f935a33c0 fix(doc): add more examples on how to run node-redis test image 2022-08-15 08:37:28 +03:00
odedponcz
cf729f3fcb
feat(test): Add integration test for the jedis and node-redis clients (#233)
* docs: Improve wording in issue reporting

Signed-off-by: odedponcz <oded@poncz.com>

* docs: Change contribution doc flow

Signed-off-by: odedponcz <oded@poncz.com>

* feat(tests): Add integration test with node-redis

Signed-off-by: odedponcz <oded@poncz.com>

* Rename integration test docker files

Signed-off-by: odedponcz <oded@poncz.com>
2022-08-12 22:42:54 +03:00
Roman Gershman
f7e58f4de2 fix(pytest): Minor fixes 2022-07-26 17:31:39 +03:00
Shmulik Klein
d2b7987ac3
test: flush all records between pytest tests #199 (#205)
test: flush all records between pytest tests
2022-07-13 12:45:29 +03:00
Shmulik Klein
1f2895e991
[WIP] test: add dragonfly_db fixture to python tests #199 (#204)
* test: add dragonfly_db fixture to it tests #199

Signed-off-by: Shmulik Klein <shmulik.klein@gmail.com>

* test: lint using flake8

Signed-off-by: Shmulik Klein <shmulik.klein@gmail.com>

* test: run dragonfly debug version as fallback

Signed-off-by: Shmulik Klein <shmulik.klein@gmail.com>
2022-07-12 17:43:46 +03:00
Roman Gershman
4ec2538204
fix(transaction): Fix rare deadlock case - fixes #150. (#155)
In rare cases a scheduled transaction is not scheduled correctly and we need
to remove it from the tx-queue in order to re-schedule. When we pull it from tx-queue
and it has been located at the head, we must poll-execute the next txs in the queue.

1. Fix the bug.
2. Improve verbosity loggings to make it easier to follow up on tx flow in release mode.
3. Introduce /txz handler that shows currently pending transactions in the queue.
4. Fix a typo in xdel() function.
5. Add a py-script that reproduces the bug.

Signed-off-by: Roman Gershman <roman@dragonflydb.io>
2022-06-15 16:53:27 +03:00
Roman Gershman
114e8bec5d Fixes #41.
1. Found dangling transaction pointers that where left in the watch queue. Fix the state machine there.
2. Improved transaction code a bit, merged duplicated code into RunInShard function, got rid of RunNoop.
3. Improved BPopper::Run flow.
4. Added 'DEBUG WATCH' command. Also 'DEBUG OBJECT' now returns shard id and the lock status of the object.
2022-05-27 12:20:01 +03:00
Roman Gershman
3a38576bbb Introduce regression tests 2022-05-27 00:26:51 +03:00
Roman Gershman
2b553535b2 Upon full segment try unloading stash buckets back to regular ones 2022-05-12 13:43:03 +03:00
Roman Gershman
0c5e2a5ecd Implement CLIENT LIST and CLIENT SETNAME. 2022-05-10 06:35:37 +03:00
Roman Gershman
d3764efbca Add CONFIG RESETSTAT command. Start working on RPOPLPUSH 2022-04-27 23:50:03 +03:00
Roman Gershman
c94d109cff Use FlatSet for Redis SETS
Add FlatSet data structure.
Use FlatSet and get rid of t_set functions.
Fix Hash bug. Add memory comparison test
2022-03-05 20:20:30 +02:00
Roman Gershman
2213c1b38b Add HKEYS command. Account for listpack blobs 2022-03-04 14:06:48 +02:00