Commit graph

3325 commits

Author SHA1 Message Date
adiholden
5147fa9595
feat (server): add flag max_squashed_cmd_num (#4964)
Signed-off-by: adi_holden <adi@dragonflydb.io>
2025-04-20 21:38:54 +03:00
Borys
707d7f0265
test: add check for removing readonly replica (#4963) 2025-04-20 12:51:56 +03:00
Roman Gershman
2ca5bf1192
chore: pass max_squash_size for MultiCommandSquasher via option (#4960)
No functionality was changed. Also fix a build error on macos.

Signed-off-by: Roman Gershman <roman@dragonflydb.io>
2025-04-20 12:14:23 +03:00
Volodymyr Yavdoshenko
a42a17f868
feat: wildcard pattern added for fields to find all non-null values (#4941)
fixed: https://github.com/dragonflydb/dragonfly/issues/4937
2025-04-18 12:47:00 +03:00
Volodymyr Yavdoshenko
954e9404c3
fix: field without @ sign in the FT.AGGREGATE command error message fixed (#4955)
fixed: https://github.com/dragonflydb/dragonfly/issues/4935
2025-04-18 10:57:39 +03:00
Roman Gershman
220f20bac6
feat: expose table capacities instead of number of buckets (#4956)
Also, add a local dashboard demonstrating prime table load per db.

Signed-off-by: Roman Gershman <roman@dragonflydb.io>
2025-04-18 10:30:04 +03:00
romange
420991d4d0 chore(helm-chart): update to v1.28.2 2025-04-17 11:49:58 +00:00
Stepan Bagritsevich
c81d99037d
fix(search_family): Fix SORTBY option in FT.SEARCH for non-sortable fields and KNN search (#4942)
* fix(search_family): Fix SORTBY option in FT.SEARCH for non-sortable fields and KNN search

fixes dragonflydb#4939, dragonflydb#4934

Signed-off-by: Stepan Bagritsevich <stefan@dragonflydb.io>

* fix compilation error

Signed-off-by: Stepan Bagritsevich <stefan@dragonflydb.io>

---------

Signed-off-by: Stepan Bagritsevich <stefan@dragonflydb.io>
Co-authored-by: Roman Gershman <roman@dragonflydb.io>
2025-04-17 13:43:25 +02:00
Kostas Kyrimis
36e6d4527c
chore: add metrics for heartbeat evictions (#4952)
* evict in heartbeat if expire table is not empty
* add metrics around heartbeat evictions (total evictions and total evicted bytes)

Signed-off-by: kostas <kostas@dragonflydb.io>
2025-04-17 13:25:40 +03:00
mkaruza
770a926b3f
fix(set_family): Transfer TTL flag from DenseLink object in delete (#4947)
fix(set_family): Transfer TTL flag from link to object in delete

When extracting DensePtr from LinkObject we need to transfer TTL flag
before this DensePtr is assigned.

Fixes #3915

Signed-off-by: mkaruza <mario@dragonflydb.io>
2025-04-17 10:55:04 +02:00
dureamPark
eba8340ad1
docs(readme): fix typo in README.ko-KR.md (#4949)
Signed-off-by: dureamPark <105711012+dureamPark@users.noreply.github.com>
Co-authored-by: Roman Gershman <roman@dragonflydb.io>
2025-04-17 06:28:57 +00:00
Roman Gershman
95147fbb59
fix: broken gha cache (#4951)
* fix: broken gha cache

Also fix some clang warnings.

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

* chore: comments

---------

Signed-off-by: Roman Gershman <roman@dragonflydb.io>
2025-04-17 08:30:58 +03:00
Roman Gershman
eb80d576d5
chore: Make snapshotting more responsive (#4910)
* chore: Make snapshotting more responsive

This should improve situation around #4787 -
maybe not solve it completely but improve it significantly.

On my tests when doing snapshotting under read traffic with master
(memtier_benchmark --ratio 0:1 -d 256  --test-time=400  --distinct-client-seed --key-maximum=2000000 -c 5 -t 2 --pipeline=3)
I got drop from 250K qps to 8K qps during the full sync phase.

With this PR, the throughput went up to 70-80K qps.

---------

Signed-off-by: Roman Gershman <roman@dragonflydb.io>
2025-04-16 07:48:23 +03:00
adiholden
b86b692461
server(bug): fix json mget crash on invalid path (#4940)
* server: fix json mget crash on invalid path

---------

Signed-off-by: adi_holden <adi@dragonflydb.io>
2025-04-15 21:56:10 +03:00
Volodymyr Yavdoshenko
d21166211d
fix: ZRANGE with LIMIT parameters crash fixed (#4944)
fixed: https://github.com/dragonflydb/dragonfly/issues/4943
2025-04-15 20:42:26 +03:00
mkaruza
9505d21047
fix(connection): Close MONITOR connection if pipeline overflows (#4889)
Close MONITOR connection if we overflow pipeline limits. It can happen
that MONITOR connection dispatches messages slower than they are received
causing memory to go out of bounds (and can result in process crash).

Signed-off-by: mkaruza <mario@dragonflydb.io>
2025-04-15 08:26:48 +02:00
Borys
5fc585b272
fix: test_migration_timeout_on_sync (#4933) 2025-04-14 20:59:42 +03:00
Volodymyr Yavdoshenko
eeb27f3569
fix: prefix search with added synonyms fixed (#4930)
fixed: https://github.com/dragonflydb/dragonfly/issues/4923
2025-04-14 19:04:05 +03:00
Volodymyr Yavdoshenko
9263fc8e92
fix: Dropping stale connections updated (#4909)
fixed: https://github.com/dragonflydb/dragonfly/issues/4893
2025-04-14 17:28:32 +03:00
mkaruza
ea17fc9893
fix(set_family): Update object time during SET FIELDEXPIRE (#4903)
StringSet object doesn't update time when FIELDEXPIRE is called. It will
use base time when object is created. Update object time when we want to
expire field in SET object.

Fixes #4894

Signed-off-by: mkaruza <mario@dragonflydb.io>
2025-04-14 13:14:40 +02:00
Stepan Bagritsevich
39a00806c9
fix(stream_family): Fix memory tracking for the STREAMs. SECOND PR (#4781)
* fix(stream_family): Fix memory tracking for the STREAMs

Signed-off-by: Stepan Bagritsevich <stefan@dragonflydb.io>

* refactor: address comments

Signed-off-by: Stepan Bagritsevich <stefan@dragonflydb.io>

---------

Signed-off-by: Stepan Bagritsevich <stefan@dragonflydb.io>
2025-04-14 13:07:17 +02:00
Borys
0997e68ddd
chore: improve SlotRanges::Merge algorithm (#4921) 2025-04-11 11:28:27 +00:00
Borys
84704a0ad3
test: add logs for cluster_mgr_test.py (#4920) 2025-04-11 09:44:04 +00:00
Abhijat Malviya
268e658376
fix: Skip test_take_over_counters for epoll (#4919) 2025-04-11 12:10:56 +05:30
mkaruza
86fb97f8a1
chore: Cleanup DbSlice::CallChangeCallbacks (#4917)
Remove key argument in DbSlice::CallChangeCallbacks which is used only
for DVLOG(2) logging. DbSlice::OnCbFinishBlocking needs to call this
function but it doesn't have key name so it has to retrieve it from
iterator.

Signed-off-by: mkaruza <mario@dragonflydb.io>
2025-04-10 16:50:32 +02:00
mkaruza
3148f1b7a3
fix(pytest): Wait exception on instance start and stop (#4916)
Pytest test_exit_on_s3_snapshot_load_err can raise exception on start in
some test environments. Now wait for exception in instance start and
stop.

Signed-off-by: mkaruza <mario@dragonflydb.io>
2025-04-10 16:49:01 +02:00
Borys
150357d960
fix: cancel blocking command during migration finalization (#4904)
* fix: cancel blocking command during migration finalization
2025-04-10 14:38:00 +00:00
Borys
d57a581303
refactor: add ability to reinit incoming migration object (#4756) 2025-04-10 13:06:50 +03:00
Harshit Gupta
09882f4150
perf: Added benchmarks for different operations in String Set. (#4866) 2025-04-10 11:50:52 +03:00
Abhijat Malviya
8d44206d41
fix(hset): Fix size account discrepancy when setting TTL (#4913)
When setting TTL, the object is cloned. An extra 4 bytes is requested
during allocation. This can result in the object being allocated from a
larger page, eg moving from 16 byte page to 32 byte page. The page block
size is used to report object allocation size. Currently this change in
size is not reflected in the total memory usage of the dense set, so it
remains 16 bytes while the object allocated size is now 32 bytes.

If such an object is later replaced, we deduct the size of the object
from total memory usage of the set. Here we can run into an overflow,
because the size of the object is deducted from the tracked size of the
set, and the former is greater than the latter.

To avoid this, if during setting expiry time the new size is different
from old size, we update the set size.
2025-04-10 12:49:11 +05:30
mkaruza
287f066d12
fix(pytest): Remove invalid argument from pytest (#4912)
Remove invalid argument in test_exit_on_s3_snapshot_load_err pytest

Signed-off-by: mkaruza <mario@dragonflydb.io>
2025-04-09 16:46:58 +00:00
Volodymyr Yavdoshenko
b1f8c9bd23
fix: invalid master_last_io_seconds_ago metric during stable sync (#4892)
fixed: https://github.com/dragonflydb/dragonfly/issues/4884
2025-04-09 14:25:08 +00:00
mkaruza
a5819aa9ca
feat(server): Exit process if error is report during initial load snapshot (#4907)
Exit process if error is reported when we try to initially load snapshot from
cloud storage or local directory.

Fixes #4840

Signed-off-by: mkaruza <mario@dragonflydb.io>
2025-04-09 14:42:28 +02:00
Abhijat Malviya
89aa54d785
fix(rdb): Print tag as int in error (#4908)
When we fail to save empty pv, its tag should be printed as int rather
than the default behaviour of trying to print uint8_t as a char.
2025-04-09 15:48:12 +05:30
Kostas Kyrimis
7adb071f2a
fix: test_replica_snapshot_with_big_values_while_seeding (#4902)
* throttle the test to require less memory
* increase reg test timeout on the ci from 50 to 60 mins

Signed-off-by: kostas <kostas@dragonflydb.io>
2025-04-09 08:20:58 +00:00
Abhijat Malviya
c129834cbf
fix(hset_family): Ensure empty hash sets are removed (#4873)
When a search operation is performed on a hash set, expired fields are
removed as a side effect.

If at the end of such an operation the hash set becomes empty, its key
is removed from the database.

Signed-off-by: Abhijat Malviya <abhijat@dragonflydb.io>
2025-04-09 12:25:43 +05:30
Kostas Kyrimis
2d96a57edf
fix: take_over_counters (#4890)
* increase delay for takeover

Signed-off-by: kostas <kostas@dragonflydb.io>
2025-04-09 09:20:21 +03:00
Borys
addf0497bf
test: tune test_cluster_migration_while_seeding to reduce false/posit… (#4901)
test: tune test_cluster_migration_while_seeding to reduce false/positive cases
2025-04-08 10:51:56 +00:00
Abhijat Malviya
e0be16b22c
pytest: temporarily skip test while its failures are investigated (#4900)
Signed-off-by: Abhijat Malviya <abhijat@dragonflydb.io>
2025-04-08 15:09:18 +05:30
mkaruza
378bcda8a2
feat(server): Move bumpup logic out of FindInternal (#4877)
Bumpup logic is moved to OnCbFinish. Previously keys which are going to
be delete were also bumped up but with this change if key doesn't exists
on callback we will skip it.

Closes #4775

Signed-off-by: mkaruza <mario@dragonflydb.io>
2025-04-07 14:15:13 +02:00
Kostas Kyrimis
b9ff1be7d8
chore: test snapshot in replica while seeding master (#4867)
Signed-off-by: kostas <kostas@dragonflydb.io>
2025-04-07 10:15:25 +00:00
Borys
2729332a0f
fix: make pause all for migration finalization (#4897) 2025-04-07 12:53:29 +03:00
Volodymyr Yavdoshenko
3a0830150e
fix: update timeout for connection test (#4895)
fixed: https://github.com/dragonflydb/dragonfly/issues/4893
2025-04-07 12:49:50 +03:00
Kostas Kyrimis
751ce58645
fix: skip heartbeat if shard is under global lock (#4882)
We allowed running heartbeat during global transactions. For example, during replication and while transitioning from full to stable sync we unregister and register journal callbacks with a preemption inbetween. If under preemption heartbeat runs, then we loose those journal entries triggering an lsn check failure.

Signed-off-by: kostas <kostas@dragonflydb.io>
2025-04-07 08:19:05 +00:00
Kostas Kyrimis
fb7a1facc8
fix: lsn check failure (#4881)
* rename StaticSeeder to DebugPopulateSeeder to show intent
* add a DCHECK in debug populate that triggers if there is a registered replica that hasn't reached stable sync
* small cleanup

Signed-off-by: kostas <kostas@dragonflydb.io>
2025-04-07 07:48:01 +00:00
Volodymyr Yavdoshenko
3eb8417453
fix: docker release should be updated latest version using semantic version of latest tag (#4887)
fixed: https://github.com/dragonflydb/dragonfly/issues/4831
2025-04-06 14:01:39 +03:00
Roman Gershman
1bfc3455fe
feat: debug compression <type> (#4879)
* feat: debug compression <type>

Extend `debug compression` to support value types.
if no type is given, falls back to testing keys compressability.

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

* Apply suggestions from code review

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Signed-off-by: Roman Gershman <roman@dragonflydb.io>

---------

Signed-off-by: Roman Gershman <roman@dragonflydb.io>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-04-05 11:01:59 +03:00
Borys
ea451e943a
fix: test_migration_rebalance_node (#4891) 2025-04-05 09:59:27 +03:00
Volodymyr Yavdoshenko
ca0cdf8c40
fix: '@text:prefix*' matching for fields. (#4868)
fixed: https://github.com/dragonflydb/dragonfly/issues/4691
2025-04-04 12:38:22 +03:00
Roman Gershman
5a2192dfdf
fix: local dashboard show rapid changes in QPS (#4886)
Helps investigating #4787

Signed-off-by: Roman Gershman <roman@dragonflydb.io>
2025-04-03 20:12:26 +03:00