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

478 commits

Author SHA1 Message Date
Kostas Kyrimis
929222a7df
chore: add mem test for big values and default the flag (#3369)
* default serialization_max_chunk_size to 10 mb
* add test for big values
* small rename of enum to conform style guide

---------

Signed-off-by: kostas <kostas@dragonflydb.io>
2024-07-24 16:07:27 +03:00
Kostas Kyrimis
cd863b89b4
chore: disable cluster_fuzzymigration (#3373)
* mark cluster_fuzzymigration as skipped

Signed-off-by: kostas <kostas@dragonflydb.io>
2024-07-24 11:46:44 +03:00
Kostas Kyrimis
cd0e03a737
chore: disable compression on big values (#3358)
*  compression when we chunk big values

Signed-off-by: kostas <kostas@dragonflydb.io>
2024-07-23 08:57:21 +00:00
Roman Gershman
aac90f25b5
fix: failure in test_cluster_fuzzymigration (#3363) 2024-07-22 22:39:41 +03:00
Roman Gershman
4b1574b5c8
chore: fix test_parser_memory_stats flakiness (#3354)
* chore: fix test_parser_memory_stats flakiness

1. Added a robust assert_eventually decorator for pytests
2. Improved the assertion condition in TieredStorageTest.BackgroundOffloading
3. Added total_uploaded stats for tiering that tells how many times offloaded values
   were promoted back to RAM.

* chore: skip test_cluster_fuzzymigration
2024-07-22 10:41:26 +00:00
Roman Gershman
feb9bc266a
chore: pull helio (#3350)
* chore: pull helio

---------

Signed-off-by: Roman Gershman <roman@dragonflydb.io>
2024-07-21 15:26:25 +03:00
Roman Gershman
fb7782bcce
chore: remove redundant metrics from memory stats (#3345)
Leave only connection memory usage in memory stats.
We should think how we can move it also to /metrics.
In addition, added a test verifying that redis parser memory
usage is tracked.

Signed-off-by: Roman Gershman <roman@dragonflydb.io>
2024-07-20 06:02:55 -04:00
Shahar Mike
2b54fd985f
fix: Cancel outgoing migration when retrying / closing (#3339) 2024-07-19 07:49:49 +00:00
Kostas Kyrimis
8a2d6ad1f4
fix: ub in RegisterOnChange and regression tests for big values (#3336)
* fix replication test flag name for big values
* fix a bug that triggers ub when RegisterOnChange is called on flows that iterate over the callbacks and preempt
* add a stress test for big value serialization

Signed-off-by: kostas <kostas@dragonflydb.io>
2024-07-19 07:03:17 +00:00
Borys
cad62679a4
Fix blocking commands moved error (#3334)
* fix: BLPOP BZPOP(MIN|MAX) moved error
2024-07-18 20:38:13 +03:00
Kostas Kyrimis
bfa5df5d6c
feat: add an option to flush serialized entries on threshold limit (#3241)
* serialize big slots in chunks
* allow preemption on large slots
* disable big entries serialization for RDB files
* add test

Signed-off-by: kostas <kostas@dragonflydb.io>
2024-07-18 10:15:41 +00:00
Borys
1acc824eff
fix(test): copy logs for failed test during TEARDOWN phase (#3331)
* fix(test): copy logs for failed test during TEARDOWN phase
2024-07-17 22:16:08 +03:00
Shahar Mike
18ca61d29b
feat(namespaces): Initial support for multi-tenant (#3260)
* feat(namespaces): Initial support for multi-tenant #3050

This PR introduces a way to create multiple, separate and isolated
namespaces in Dragonfly. Each user can be associated with a single
namespace, and will not be able to interact with other namespaces.

This is still experimental, and lacks some important features, such as:
* Replication and RDB saving completely ignores non-default namespaces
* Defrag and statistics either use the default namespace or all
  namespaces without separation

To associate a user with a namespace, use the `ACL` command with the
`TENANT:<namespace>` flag:

```
ACL SETUSER user TENANT:namespace1 ON >user_pass +@all ~*
```

For more examples and up to date info check
`tests/dragonfly/acl_family_test.py` - specifically the
`test_namespaces` function.
2024-07-16 19:34:49 +03:00
Borys
3891efac2c
fix: forbid DFLYCLUSTER commads set for emulated cluster mode (#3307)
* fix: forbid DFLYCLUSTER commads set for emulated cluster mode
* feat: add CLUSTER MYID and remove DFLYCLUSTER MYID
* fix(test): __del__ method in python can't be async
* fix: crash and test_replicate_disconnect_cluster
2024-07-16 14:17:28 +03:00
adiholden
f20318d88a
fix (pytest): generate unique random dbfilename for tests (#3317)
Signed-off-by: adi_holden <adi@dragonflydb.io>
2024-07-15 11:01:02 +03:00
Kostas Kyrimis
bf1b6cef6e
chore: skip test_cluster_flushall_during_migration (#3316)
* skip failing test on ci

Signed-off-by: kostas <kostas@dragonflydb.io>
2024-07-15 09:48:28 +03:00
Kostas Kyrimis
73abd68f2d
chore(acl): add test with requirepass and aclfile (#3312)
* add a test that uses both requirepass and aclfile

Signed-off-by: kostas <kostas@dragonflydb.io>
2024-07-15 08:28:29 +03:00
Shahar Mike
1daa80117c
fix(tests): Add missing awaits (#3273)
Also add some more logs to help debug teardown timeout issues
2024-07-11 11:46:28 +03:00
Kostas Kyrimis
9782eb2ac4
fix(acl): loading interleaved plain and hashed passwords (#3297)
* fix a bug of rehashing hashed passwords while loading plan/hashed passwords from acl file

Signed-off-by: kostas <kostas@dragonflydb.io>
2024-07-10 12:40:40 +00:00
Borys
21620ef46f
fix: missing logs on pytest failures #3255 (#3272)
* fix: missing logs on pytest failures #3255
2024-07-10 10:58:54 +03:00
adiholden
5c7c21b6c5
fix(bug): crash on takeover and info replication (#3282)
Signed-off-by: adi_holden <adi@dragonflydb.io>
2024-07-08 17:21:12 +03:00
Roman Gershman
fba902d0ac
fix: properly clean tiered state upon flash (#3281)
* fix: properly clean tiered state upon flash

The bug was around io pending entries that have not been properly cleaned during flush.
This PR simplified the logic around tiered storage handling during flush, it always performs the
cleaning in the synchronous part of the command.

In addition, this PR improves error logging in tests if dragonfly process exits with an error.
Finally, a test is added that makes sure pending tiered items are flushed during the flash call.

Fixes #3252
---------

Signed-off-by: Roman Gershman <roman@dragonflydb.io>
2024-07-08 10:43:11 +03:00
Shahar Mike
4fd6ba68a2
fix: Increase key count to make test more robust (#3286) 2024-07-08 07:10:03 +00:00
Shahar Mike
2f09055260
chore: Disable cluster_mgr_test (#3279) 2024-07-08 09:12:27 +03:00
Shahar Mike
daa7e3708c
fix(test): Verify that save has not finished (#3278)
fix(test): Verify that save has not finished, otherwise it's an endless loop
2024-07-08 08:33:44 +03:00
Vladislav
2bf4451ec7
fix(tiering): Throttle snapshot load (#3249) 2024-07-04 17:10:23 +03:00
Roman Gershman
d8946247df
chore: upload all the logs from /tmp (#3263)
Signed-off-by: Roman Gershman <roman@dragonflydb.io>
2024-07-04 09:17:25 +03:00
Borys
84814a7358
fix: fix move error during migration finalization (#3253)
* fix: fix Move error during migration finalization
2024-07-02 14:23:54 +03:00
Kostas Kyrimis
5956275818
chore: replace session wide fixtures with scope (#3251)
* chore: replace session wide fixtures with scope
2024-07-02 10:26:26 +03:00
Roman Gershman
0e375295e8
chore: introduce back-pressure to tiered storage (#3243)
* chore: introduce back-pressure to tiered storage

Also, so clean-up with mac-os daily build.


Enabled forgotten test.
Improve CI insights

---------

Signed-off-by: Roman Gershman <roman@dragonflydb.io>
2024-06-30 15:46:11 +03:00
Vladislav
4cc9834d89
fix(pytest): timed ticker for simpler conditions (#3242)
Signed-off-by: Vladislav Oleshko <vlad@dragonflydb.io>
2024-06-29 15:48:25 +03:00
Roman Gershman
b34d3ba6da
chore(tiered): minor fixes + expose buffer allocation type stats (#3234)
* chore(tiered): minor fixes + expose buffer allocation type stats

fixes small_bins deletion logic

Fixes #3240
---------

Signed-off-by: Roman Gershman <roman@dragonflydb.io>
2024-06-29 11:42:17 +03:00
Vladislav
c1bde661fb
chore: disable tiering test (#3236)
Signed-off-by: Vladislav Oleshko <vlad@dragonflydb.io>
2024-06-28 10:01:42 +03:00
Kostas Kyrimis
847e2edc09
fix: replicaof_reject_on_load flake (#3203) 2024-06-25 13:52:17 +03:00
Vladislav
4357933775
feat(server): expiry notifications (#3154)
Adds basic support for keyspace notifications, only Ex

Signed-off-by: Vladislav Oleshko <vlad@dragonflydb.io>
2024-06-24 16:23:40 +03:00
Vladislav
cf9ac35596
chore: fix tiering regtest test (#3208) 2024-06-23 12:02:46 +03:00
Kostas Kyrimis
e097248baf
chore: add replica-priority flag (#3204)
* add replica-priority flag
* add it on info replication command
* add test
2024-06-22 00:34:48 +03:00
Vladislav
40ede6f61a
chore(tiering): More advanced tiering tests (#3201)
* chore(tiering): More advanced tiering tests

* fix: fixes
2024-06-21 23:47:59 +03:00
Kostas Kyrimis
f01aa2d76b
feat(acl): add support of multiple passwords (#3189)
* add support for multiple passwords
* add support for deleting passwords
* add support for resetpass
* add tests
* always prefix passwords with hashtag when printed
2024-06-21 20:39:33 +03:00
Shahar Mike
48c6f4bf74
chore: Re-enable previously flaky test (#3196) 2024-06-21 13:12:14 +03:00
Shahar Mike
6024d79bd6
feat(cluster): Support STICK bit in slot migration (#3200) 2024-06-21 08:18:03 +03:00
Shahar Mike
c8f2f253d6
test(cluster): Make sure migration maintains TTL (#3188) 2024-06-20 20:46:38 +03:00
Borys
4e7f6dc6ed
test: improve cluster_fuzzy_migration test (#3197) 2024-06-20 19:09:15 +03:00
Shahar Mike
43d7993cda
fix(server): Rename confusing flag replica_reconnect_on_master_restart (#3193)
That was a misleading name, as the logic was the exact opposite (oops 🤦)

This PR introduces a new name for the same flag: break_replication_on_master_restart

We're keeping the previous flag for now, to make transition easier. We'll remove it in a later Dragonfly version (>= 1.22)

Fixes #3192
2024-06-20 15:09:33 +03:00
Stepan Bagritsevich
0156325590
fix(generic_family): fix RenameGeneric command for non-string data types (#3181)
* fix(generic_family): fix RenameGeneric command for non-string data types

fixes dragonflydb#3107, fixes dragonflydb#3113, fixes dragonflydb#307

Signed-off-by: Stepan Bagritsevich <bagr.stepan@gmail.com>

* refactor: address comments

Signed-off-by: Stepan Bagritsevich <bagr.stepan@gmail.com>

* refactor: address comments 2

Signed-off-by: Stepan Bagritsevich <bagr.stepan@gmail.com>

---------

Signed-off-by: Stepan Bagritsevich <bagr.stepan@gmail.com>
2024-06-20 14:03:05 +04:00
Shahar Mike
f66ee5f47d
fix(cluster): Support FLUSHALL while slot migration is in progress (#3173)
* fix(cluster): Support `FLUSHALL` while slot migration is in progress

Fixes #3132

Also do a small refactor to move cancellation logic into
`RestoreStreamer`.
2024-06-20 11:40:23 +03:00
Kostas Kyrimis
d207789610
chore(ci): run replication tests on arm (#3168)
* combine replication tests and reg tests in one flow
* allow replication tests to run on arm
2024-06-18 16:48:35 +03:00
Kostas Kyrimis
8d82581c96
chore: small acl compat changes (#3177)
* print categories and commands in lower case instead of capital case
* fix a bug of default user inheriting the wrong acl rules on new connections
* move keys position to be after password when printed from an acl command
2024-06-17 09:40:41 +03:00
adiholden
805c024fc2
fix(server): fix bug in replication on cached mode (#3156)
* fix server: fix replication on cached mode

Signed-off-by: adi_holden <adi@dragonflydb.io>
2024-06-17 08:37:58 +03:00
Vladislav
c08719117c
feat(json): MSET (#3167)
Signed-off-by: Vladislav Oleshko <vlad@dragonflydb.io>
2024-06-13 12:33:24 +03:00