[MOD-13846] Add numeric_range_tree_ffi crate (FFI bindings for insert/find/iter)#8305
[MOD-13846] Add numeric_range_tree_ffi crate (FFI bindings for insert/find/iter)#8305LukeMathWalker merged 3 commits intomasterfrom
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #8305 +/- ##
==========================================
+ Coverage 82.86% 82.89% +0.02%
==========================================
Files 420 421 +1
Lines 60825 62021 +1196
Branches 18695 19116 +421
==========================================
+ Hits 50405 51411 +1006
- Misses 10233 10420 +187
- Partials 187 190 +3
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
2e6c296 to
d9d4e51
Compare
21e0009 to
b6fbd83
Compare
src/redisearch_rs/c_entrypoint/numeric_range_tree_ffi/src/gc.rs
Outdated
Show resolved
Hide resolved
d9d4e51 to
28993f6
Compare
fbbb37a to
b5e029f
Compare
28993f6 to
69d255a
Compare
|
b5e029f to
a581c7e
Compare
69d255a to
2d66944
Compare
a581c7e to
d0d73a0
Compare
2d66944 to
1fa3b06
Compare
|
d0d73a0 to
a1a7e8b
Compare
1fa3b06 to
4f38267
Compare
|
4f38267 to
e873c7f
Compare
a1a7e8b to
f270d70
Compare
|
f270d70 to
668ebcf
Compare
e873c7f to
0aa6d28
Compare
668ebcf to
cf7bfc6
Compare
0aa6d28 to
5ec972a
Compare
cf7bfc6 to
a49d169
Compare
5de5df1 to
494fed2
Compare
a49d169 to
7d40a5c
Compare
b72444e to
5c42040
Compare
54d2f47 to
6b3d750
Compare
5c42040 to
ba1411a
Compare
|
ba1411a to
42deea6
Compare
6b3d750 to
92713bf
Compare
42deea6 to
9cb1e97
Compare
src/redisearch_rs/c_entrypoint/numeric_range_tree_ffi/src/lib.rs
Outdated
Show resolved
Hide resolved
9cb1e97 to
be0e1f9
Compare
src/redisearch_rs/c_entrypoint/numeric_range_tree_ffi/src/lib.rs
Outdated
Show resolved
Hide resolved
src/redisearch_rs/c_entrypoint/numeric_range_tree_ffi/src/lib.rs
Outdated
Show resolved
Hide resolved
src/redisearch_rs/c_entrypoint/numeric_range_tree_ffi/src/debug.rs
Outdated
Show resolved
Hide resolved
be0e1f9 to
f0c7711
Compare
f0c7711 to
5fc6411
Compare
5fc6411 to
55b3c0b
Compare
❌ Jit Scanner failed - Our team is investigatingJit Scanner failed - Our team has been notified and is working to resolve the issue. Please contact support if you have any questions. 💡 Need to bypass this check? Comment |
788d205 to
34f2968
Compare
|
❌ The last analysis has failed. |



Describe the changes in the pull request
Add FFI bindings to expose the functionality provided by
numeric_range_treeto the C codebase.Which additional issues this PR fixes
Main objects this PR modified
Mark if applicable
Release Notes
If a release note is required (bug fix / new feature / enhancement), describe the user impact of this PR in the title.
Note
Medium Risk
Introduces new FFI surface area and tweaks GC scanning/callback plumbing in
numeric_range_tree, where mistakes can lead to UB, leaks, or subtle GC/cardinality regressions; changes are largely additive but touch unsafe boundaries.Overview
Adds a new
numeric_range_tree_fficrate that exposes the Rustnumeric_range_treeto C via a generatedheaders/numeric_range_tree.h, including lifecycle (NewNumericRangeTree/_Free), insert (NumericRangeTree_Add), query (NumericRangeTree_Find), iteration, range accessors, and FT.DEBUG-oriented dump/summary helpers.Refactors numeric-range-tree internals to better support GC/FFI:
NumericIndex::scan_gcnow accepts an optional per-entry repair callback,NumericRangeNode::scan_gcis added to compute both GC deltas and HLL cardinality registers, and several result structs are marked#[repr(C)]with new raw-part constructors (Key/NodeIndex) for round-tripping through C. Build/bindgen is updated to blocklistnumeric_range_tree.h,inverted_index_ffiexposesfork_gcpublicly, and workspace lock/hack dependencies are updated (notably addingredis-module).Written by Cursor Bugbot for commit 788d205. This will update automatically on new commits. Configure here.