MOD-8391: Report active threads-indexes upon crash#5403
Conversation
e523267 to
24424cf
Compare
src/activeThreads.c
Outdated
| activeThreads = rm_calloc(1, sizeof(ActiveThreads)); | ||
| dllist_init(&activeThreads->list); | ||
| pthread_mutex_init(&activeThreads->lock, NULL); | ||
| pthread_key_create(&_activeThreadKey, NULL); |
There was a problem hiding this comment.
seems like you can specify a destructor for when the thread exits, maybe use it to remove the link from the list?
There was a problem hiding this comment.
Can you elaborate?
I want the scope of the link to be the same as the scope of the use of the StrongRef of the index by the thread.
There was a problem hiding this comment.
Was wondering if it is possible for a thread to exit without actively removing the link from the linked list.
Another option would be for the callback to just verify/assert the link was removed from the list.
That feels like it would catch early development bugs if the add remove interaction flow with the linked list changes.
There was a problem hiding this comment.
Notice the need for the StrongRef to be valid, which may not be the case after it is released in the thread.
I will add the assertion, seems the safest and most reasonable option.
| // we use the global reference as our guard and access the spec dierctly. | ||
| // This function consumes the Strong reference it gets | ||
| void IndexSpec_RemoveFromGlobals(StrongRef spec_ref) { | ||
| void IndexSpec_RemoveFromGlobals(StrongRef spec_ref, bool removeActive) { |
There was a problem hiding this comment.
not sure about tying thread stuff with index object.
Feels like we shouldn't tie them together
There was a problem hiding this comment.
We release the strong ref here, which is also the latest time I want to be in the active-threads container.
If we don't do this, we miss some important coverage.
There was a problem hiding this comment.
Remove from globals also gets called when the ref count reaches 0.
So it is possible that the same thread will call activeThreads_RemoveCurrentThread twice.
I think being strict here and knowing when we release will benefit us in the long run.
Edit: I now see you pass false in almost all the cases.
Also seems like it only gets called once with true, in drop index command.
Seems an excessive change for one use case.
There was a problem hiding this comment.
The trade-off of adding the argument for more coverage seems good to me, since in the release process many things can go wrong.
It's not that an argument is such a hustle or logic changer.
Don't you think the trade-off is worth it?
There was a problem hiding this comment.
From my experience tying threads to objects causes more confusion.
Separating thread state management from objects is better IMHO in the long run.
There was a problem hiding this comment.
I think this argument makes sense, as we are looking at the releasing flow of an index.
The alternative yields uncovered flows, which is not a good tradeoff IMO.
How would you do this otherwise, without loosing this coverage?
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #5403 +/- ##
==========================================
- Coverage 87.88% 87.06% -0.83%
==========================================
Files 207 211 +4
Lines 37546 37778 +232
Branches 1229 1229
==========================================
- Hits 32996 32890 -106
- Misses 4545 4883 +338
Partials 5 5 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
active-queries container
src/active_threads.c
Outdated
| activeThreads = rm_calloc(1, sizeof(ActiveThreads)); | ||
| dllist_init(&activeThreads->list); | ||
| pthread_mutex_init(&activeThreads->lock, NULL); | ||
| pthread_key_create(&_activeThreadKey, NULL); |
There was a problem hiding this comment.
Are we sure we don't want to use the callback function to verify the thread removed the link from the linked list when it finishes running?
It can help us detect leaks in our logic.
There was a problem hiding this comment.
Will think about it, I'm not sure it will have added value.
src/active_threads.c
Outdated
| pthread_mutex_unlock(&activeThreads->lock); | ||
|
|
||
| // Free the node | ||
| rm_free(at); |
There was a problem hiding this comment.
Maybe the rm_free can happen in the custom dtor we can specify in pthread_key_create?
It removes the constant allocation/deallocation from each query.
There was a problem hiding this comment.
Interesting idea, will look into the pthread_key destructor behavior.
| // we use the global reference as our guard and access the spec dierctly. | ||
| // This function consumes the Strong reference it gets | ||
| void IndexSpec_RemoveFromGlobals(StrongRef spec_ref) { | ||
| void IndexSpec_RemoveFromGlobals(StrongRef spec_ref, bool removeActive) { |
There was a problem hiding this comment.
From my experience tying threads to objects causes more confusion.
Separating thread state management from objects is better IMHO in the long run.
kei-nan
left a comment
There was a problem hiding this comment.
Roles got switched during development.
Approving on behalf of Raz.
|
Backport failed for Please cherry-pick the changes locally and resolve any conflicts. git fetch origin 2.10
git worktree add -d .worktree/backport-5403-to-2.10 origin/2.10
cd .worktree/backport-5403-to-2.10
git switch --create backport-5403-to-2.10
git cherry-pick -x 384a2f6a2fc21525202044752d67113facb5e8be |
|
Backport failed for Please cherry-pick the changes locally and resolve any conflicts. git fetch origin 8.0
git worktree add -d .worktree/backport-5403-to-8.0 origin/8.0
cd .worktree/backport-5403-to-8.0
git switch --create backport-5403-to-8.0
git cherry-pick -x 384a2f6a2fc21525202044752d67113facb5e8be |
* Add new activeThreads API * Fix docs, add container populatoin * Add logging in crash * Add Linux thread id to log, add GC thread to active threads container * Add main-thread registrations * Fix * fix initialization * Address review * Fix leak * Fix assertion * Touchup * * pivot - keep track of the active queries and cursors in the main thread when blocking the client - keep track at each thread the spec it is working on. * * fix spellcheck error * fix compilation * * fix spellcheck typo * * fix tests * * wrong function name - should be CaseInsensitiveCompare * * revert * * fix typos * * fix some tests * * bring back old code that was removed by mistake * * add a dtor function to the thread local variable to avoid reallocating on every set * * do not omit argument name - fixes compilation error on some operating systems * * add missing includes * * change include order * * cleanup memory in CurrentThread_ClearIndexSpec to avoid thread lifetime leak. * * try and upload the so library as an artifact on failure * * fix typo * * also upload the debug symbols as an artifact * * add debug symbols to diagnose crash * * suspect the reference mechanism is not atomic enough * unified strong and weak ref count into a single variable to ensure atomicity * * change Strong value and make it 64 bit * * revert some changes that were made to locate the gc crash * don't set the index spec in the gc thread * * missed a set call - commented it out * * fix gc flow - use weak ref to take into account race condition of index deletion after first strong ref is taken. * try and use free callback for thread local variable * * update comment * add a log in case thread forgot to cleanup * * remove unneeded fields * code cleanup * duplicate index name to output something if promote fails during crash * * fix tests * * fix return for ThreadLocalStorage_Init * * add CurrentThread_TryGetSpecInfo * use CurrentThread_TryGetSpecInfo in info_redis.c * some code cleanup * * fix compilation error * * clear spec in DistAggregateCleanups * * code review comments * * fix typo * * code review comments * restructured the files, moved them to be under info folder * cursor object is retrieved in main thread * if it is a shard cursor we will add it to the blocked queries cursor list * * try and take a strong ref when dealing in cursor query * * add result processor when using debug search commands to allow crashing the query * add a test to check the additional crash information is correct * * small code review fixes * * change error so test will pass * use correct submodule * * code review comments - Andres * - make set and clear part of the ref promote and release. - found a few more places where we could set the index spec * - fix leak * - raz code review comments --------- Co-authored-by: jonathan keinan <[email protected]> (cherry picked from commit 384a2f6)
MOD-8391: Report active threads-indexes upon crash (#5403) * Add new activeThreads API * Fix docs, add container populatoin * Add logging in crash * Add Linux thread id to log, add GC thread to active threads container * Add main-thread registrations * Fix * fix initialization * Address review * Fix leak * Fix assertion * Touchup * * pivot - keep track of the active queries and cursors in the main thread when blocking the client - keep track at each thread the spec it is working on. * * fix spellcheck error * fix compilation * * fix spellcheck typo * * fix tests * * wrong function name - should be CaseInsensitiveCompare * * revert * * fix typos * * fix some tests * * bring back old code that was removed by mistake * * add a dtor function to the thread local variable to avoid reallocating on every set * * do not omit argument name - fixes compilation error on some operating systems * * add missing includes * * change include order * * cleanup memory in CurrentThread_ClearIndexSpec to avoid thread lifetime leak. * * try and upload the so library as an artifact on failure * * fix typo * * also upload the debug symbols as an artifact * * add debug symbols to diagnose crash * * suspect the reference mechanism is not atomic enough * unified strong and weak ref count into a single variable to ensure atomicity * * change Strong value and make it 64 bit * * revert some changes that were made to locate the gc crash * don't set the index spec in the gc thread * * missed a set call - commented it out * * fix gc flow - use weak ref to take into account race condition of index deletion after first strong ref is taken. * try and use free callback for thread local variable * * update comment * add a log in case thread forgot to cleanup * * remove unneeded fields * code cleanup * duplicate index name to output something if promote fails during crash * * fix tests * * fix return for ThreadLocalStorage_Init * * add CurrentThread_TryGetSpecInfo * use CurrentThread_TryGetSpecInfo in info_redis.c * some code cleanup * * fix compilation error * * clear spec in DistAggregateCleanups * * code review comments * * fix typo * * code review comments * restructured the files, moved them to be under info folder * cursor object is retrieved in main thread * if it is a shard cursor we will add it to the blocked queries cursor list * * try and take a strong ref when dealing in cursor query * * add result processor when using debug search commands to allow crashing the query * add a test to check the additional crash information is correct * * small code review fixes * * change error so test will pass * use correct submodule * * code review comments - Andres * - make set and clear part of the ref promote and release. - found a few more places where we could set the index spec * - fix leak * - raz code review comments --------- Co-authored-by: jonathan keinan <[email protected]> (cherry picked from commit 384a2f6) Co-authored-by: Raz Monsonego <[email protected]>
* Add new activeThreads API * Fix docs, add container populatoin * Add logging in crash * Add Linux thread id to log, add GC thread to active threads container * Add main-thread registrations * Fix * fix initialization * Address review * Fix leak * Fix assertion * Touchup * * pivot - keep track of the active queries and cursors in the main thread when blocking the client - keep track at each thread the spec it is working on. * * fix spellcheck error * fix compilation * * fix spellcheck typo * * fix tests * * wrong function name - should be CaseInsensitiveCompare * * revert * * fix typos * * fix some tests * * bring back old code that was removed by mistake * * add a dtor function to the thread local variable to avoid reallocating on every set * * do not omit argument name - fixes compilation error on some operating systems * * add missing includes * * change include order * * cleanup memory in CurrentThread_ClearIndexSpec to avoid thread lifetime leak. * * try and upload the so library as an artifact on failure * * fix typo * * also upload the debug symbols as an artifact * * add debug symbols to diagnose crash * * suspect the reference mechanism is not atomic enough * unified strong and weak ref count into a single variable to ensure atomicity * * change Strong value and make it 64 bit * * revert some changes that were made to locate the gc crash * don't set the index spec in the gc thread * * missed a set call - commented it out * * fix gc flow - use weak ref to take into account race condition of index deletion after first strong ref is taken. * try and use free callback for thread local variable * * update comment * add a log in case thread forgot to cleanup * * remove unneeded fields * code cleanup * duplicate index name to output something if promote fails during crash * * fix tests * * fix return for ThreadLocalStorage_Init * * add CurrentThread_TryGetSpecInfo * use CurrentThread_TryGetSpecInfo in info_redis.c * some code cleanup * * fix compilation error * * clear spec in DistAggregateCleanups * * code review comments * * fix typo * * code review comments * restructured the files, moved them to be under info folder * cursor object is retrieved in main thread * if it is a shard cursor we will add it to the blocked queries cursor list * * try and take a strong ref when dealing in cursor query * * add result processor when using debug search commands to allow crashing the query * add a test to check the additional crash information is correct * * small code review fixes * * change error so test will pass * use correct submodule * * code review comments - Andres * - make set and clear part of the ref promote and release. - found a few more places where we could set the index spec * - fix leak * - raz code review comments --------- Co-authored-by: jonathan keinan <[email protected]> (cherry picked from commit 384a2f6)
* WIP new coverage flow * move coverage logic to task-test.yml and build.sh * type change and rust test fixes * comment-out run_miri input * minor fixes and improvements * update file paths * fix build for coverage * remove redundancy * fix redis build * fix command * another attempt * fix * run against latest redis * fix coordinator env vars * add missing rust tests * don't run rust tests on sanitizer (for now) * attempt to fix coverage capture * attempt to fix rust sanitizer * attempt to fix the rust test instead * replace single quotes with double quotes * improve prints * remove quotes * attempt to fix unit-test paths * debug build on coverage * cleanups * Revert "MOD-8391: Report active threads-indexes upon crash (#5403)" This reverts commit 384a2f6. * Reapply "MOD-8391: Report active threads-indexes upon crash (#5403)" This reverts commit ed38b62. * better capture * add a tests extraction step for a unified flow in older versions * fix step to allow no-op
* WIP new coverage flow * move coverage logic to task-test.yml and build.sh * type change and rust test fixes * comment-out run_miri input * minor fixes and improvements * update file paths * fix build for coverage * remove redundancy * fix redis build * fix command * another attempt * fix * run against latest redis * fix coordinator env vars * add missing rust tests * don't run rust tests on sanitizer (for now) * attempt to fix coverage capture * attempt to fix rust sanitizer * attempt to fix the rust test instead * replace single quotes with double quotes * improve prints * remove quotes * attempt to fix unit-test paths * debug build on coverage * cleanups * Revert "MOD-8391: Report active threads-indexes upon crash (#5403)" This reverts commit 384a2f6. * Reapply "MOD-8391: Report active threads-indexes upon crash (#5403)" This reverts commit ed38b62. * better capture * add a tests extraction step for a unified flow in older versions * fix step to allow no-op
* WIP new coverage flow * move coverage logic to task-test.yml and build.sh * type change and rust test fixes * comment-out run_miri input * minor fixes and improvements * update file paths * fix build for coverage * remove redundancy * fix redis build * fix command * another attempt * fix * run against latest redis * fix coordinator env vars * add missing rust tests * don't run rust tests on sanitizer (for now) * attempt to fix coverage capture * attempt to fix rust sanitizer * attempt to fix the rust test instead * replace single quotes with double quotes * improve prints * remove quotes * attempt to fix unit-test paths * debug build on coverage * cleanups * Revert "MOD-8391: Report active threads-indexes upon crash (#5403)" This reverts commit 384a2f6. * Reapply "MOD-8391: Report active threads-indexes upon crash (#5403)" This reverts commit ed38b62. * better capture * add a tests extraction step for a unified flow in older versions * fix step to allow no-op
* WIP new coverage flow * move coverage logic to task-test.yml and build.sh * type change and rust test fixes * comment-out run_miri input * minor fixes and improvements * update file paths * fix build for coverage * remove redundancy * fix redis build * fix command * another attempt * fix * run against latest redis * fix coordinator env vars * add missing rust tests * don't run rust tests on sanitizer (for now) * attempt to fix coverage capture * attempt to fix rust sanitizer * attempt to fix the rust test instead * replace single quotes with double quotes * improve prints * remove quotes * attempt to fix unit-test paths * debug build on coverage * cleanups * Revert "MOD-8391: Report active threads-indexes upon crash (#5403)" This reverts commit 384a2f6. * Reapply "MOD-8391: Report active threads-indexes upon crash (#5403)" This reverts commit ed38b62. * better capture * add a tests extraction step for a unified flow in older versions * fix step to allow no-op
* test config set doesnt effect other configs * change config setters and getters * handle isInverted * fix partial indexes tests * rename cluster_timeout * fix py test * refactor tests * mll change to test * Some cargo clippy fixes (#6122) Clippy fixes * Use the correct Rust profile for every task (#6128) * Compute coverage for Rust tests in CI (#6127) * restore macos-latest-xlarge (#6132) * CI - update release flow - [MOD-9681] (#6131) * change release flow to be triggered by a tag push * TEMP call this branch 3.2.1 * dummy content * fix branch validation * improve error message * revert temporary changes * improve message * [MOD-9694] Trie prefixes iterator (#6119) * Prefixes iterator * Align with C: do not track keys in the prefixes iterator * Compile arr.h as a standalone static library * Fix memory issue in bench * Add license header * Re-add tests for values iterator * Add another prefix benchmark using the full Gutenberg dataset. * [MOD-9693] IntoValues trie iterator. (#6129) IntoValues iterator * rockylinux:8 install python3.12 packages (#6147) rockylinux:8 install python3.12-devel * Fix linting failure on Rust LowMemoryThinVec drop implementation (#6146) replace `mem::replace` with `mem::take` * [master] [8.0] Remove -Werror linker flags [MOD-9624] (#6105) [8.0] Remove -Werror linker flags [MOD-9624] (#6104) * remove linker flag -werror * remove linker flag -werror - one more (cherry picked from commit 5688fcc) Co-authored-by: alonre24 <[email protected]> * Coverage Report Without `readies` - Phase 2 - [MOD-6711] (#5909) * WIP new coverage flow * move coverage logic to task-test.yml and build.sh * type change and rust test fixes * comment-out run_miri input * minor fixes and improvements * update file paths * fix build for coverage * remove redundancy * fix redis build * fix command * another attempt * fix * run against latest redis * fix coordinator env vars * add missing rust tests * don't run rust tests on sanitizer (for now) * attempt to fix coverage capture * attempt to fix rust sanitizer * attempt to fix the rust test instead * replace single quotes with double quotes * improve prints * remove quotes * attempt to fix unit-test paths * debug build on coverage * cleanups * Revert "MOD-8391: Report active threads-indexes upon crash (#5403)" This reverts commit 384a2f6. * Reapply "MOD-8391: Report active threads-indexes upon crash (#5403)" This reverts commit ed38b62. * better capture * add a tests extraction step for a unified flow in older versions * fix step to allow no-op * CI Improvements (#6153) * improvements * use job-based concurrency * notify benchmark failure only on push * improve job name * test notification * skip actual benchamrks * Revert "skip actual benchamrks" This reverts commit 59e8fb2. * Revert "test notification" This reverts commit 1661e0a. * re-implement notification condition with input * test * Revert "test" This reverts commit 80206ae. * cleanup * test recent changes * change and test * fix * cleanup * fixes * Add .cache to git ignore list (#6157) Seems clang creates a cache under this directory, so let's put it to git ignore list. * Remove base64 code from codebase (#6161) remove base64 code * [MOD-9372 , MOD-9733] Stop indexing OOM - Add wait before OOM (#6114) * Add config * insert oom_scan field to scanner, remove check for oom in debug pause on oom * fix comment * create basis for function * handle last scanned key * change sleep function name * Add pause before and after reset * Add pause before and after statuses code * Add pause before and after reset to bg scan * wait if config >0 * adjust default sleep time * fix last scanned key * temp tests * bsaic test strcuture * styling * Add scanner status strings * Add first test * Add update option for dbug scanner and more tests * remove scanner cancleation * Alter and Drop tests * spellcheck * skip cluster in tests * Add config test for new config * shortern tests * styling * remove pause on OOM from drop test * Add tests, style * style * style * Remove unused pause after OOM reset * debug commands tests and cluster tests * Naming, styling, formatting * rename, change structure for simplicity * improve test robustness * remove unused and move to better location * Ben comments round1 * Add 0 thresh test * comment * ADd skip cluster * change config and other Alon's comments * small tess * remove pause after Remove duplicates in tests * more test compression * fix assert * Temp disable coverage as required for CI to pass in PRs (#6166) temp to allow PRs * [MOD-9735] Track the number of unique keys in the trie. (#6156) Track the number of unique keys in the trie. * [MOD-9692] Wildcard trie iterator. (#6130) Wildcard trie iterator * Fix micro-benchmarking job on master branch (#6162) Fix workspace benching * Use the correct profile name for Rust debug builds (#6170) * Add More Diagnostics When Active Queries Are Not Empty (#6167) * initial commit * Apply suggestions from code review Co-authored-by: GuyAv46 <[email protected]> * code review comments * output the explain string for queries if hide user data from logs is off when dumping queries * fix typo * free allocated query string --------- Co-authored-by: GuyAv46 <[email protected]> * [MOD-9372 , MOD-9733] Stop indexing OOM - Add wait before OOM (#6114) * Add config * insert oom_scan field to scanner, remove check for oom in debug pause on oom * fix comment * create basis for function * handle last scanned key * change sleep function name * Add pause before and after reset * Add pause before and after statuses code * Add pause before and after reset to bg scan * wait if config >0 * adjust default sleep time * fix last scanned key * temp tests * bsaic test strcuture * styling * Add scanner status strings * Add first test * Add update option for dbug scanner and more tests * remove scanner cancleation * Alter and Drop tests * spellcheck * skip cluster in tests * Add config test for new config * shortern tests * styling * remove pause on OOM from drop test * Add tests, style * style * style * Remove unused pause after OOM reset * debug commands tests and cluster tests * Naming, styling, formatting * rename, change structure for simplicity * improve test robustness * remove unused and move to better location * Ben comments round1 * Add 0 thresh test * comment * ADd skip cluster * change config and other Alon's comments * small tess * remove pause after Remove duplicates in tests * more test compression * fix assert * mention BM25 as default scorer in README (#6165) * Yield to redis while indexing - [MOD-9220] (#6103) * add op-counter + config * Run all Rust benchmarks in the workspace (#6030) * Run all Rust benchmarks in the workspace * Allow forcing the run for micro-benchmarks * Fix bench run * Update .github/workflows/flow-micro-benchmarks.yml Co-authored-by: Tim Janus <[email protected]> --------- Co-authored-by: Tim Janus <[email protected]> * Fix Rust build after switching off readies (#6086) Fix Rust linking * [MOD-9560] Change default config value for _BG_INDEX_MEM_PCT_THR (#6053) * change default value * change default value in config pytest * change index oom tests to lower value then new default * change debug commands tests to lower value then default value * change default value of set tight memory functions * 100testv1 * test default value * Build unit tests without readies [MOD-9099] (#6082) * purge readeis from cmake. Use new build script instead of makefile * call script in CI * libuv * restore build folder * libuv * unit tests * pretty build.sh * pytest * fixed extension build error * Add profile flags + try pass linker flag properly (wip) * fix build and linkage + pytest + adjust json * small cleanup * Add pytz dep * bump googletest version, use same variant name as before * remove ld libs * Fix executable linker flags - build unit test properly. run unit tests with old "make unit-tests" way (until this is fixed via ./build.sh) * fix rust build via build.sh * fix san build * Set coverage flags and use the same bin dir for sanitizer (build it for debug) * update benchmark image for regression test * remove leftover * Build hiredis static * fix json env flag in CI * CR changes * Restore deleted files until unit tests are done as well, use boolean params * restore vecsim version * fix profile and fix build error * fix for profile * try fix mac build * fix unit tests for arm * Define boost dir * remove the policies * try fix the binroot for unit-tests * change dir name for arm * remove policy from hash as well * use clang in mac * try to set hardcoded clang * try to mimic readies in macos includes * try set CMAKE_OSX_DEPLOYMENT_TARGET * whitespace formatting * Set CC to clang in apple * try to export llvm * try set compiler in build script * use bin in path * try EXPORT properly with homebrew * remove setting bad path to clang * set clang path * update to llvm@18 * update c++ path * set compiler with LLVM env var * fix? * set proper link flags for mac * remove bsymbolic from hiredis * revert hiredis in non macos to how it was * clean stuff * cleanups * Fix the extract debug symbols command so it will work as before (required for packing properly) * update deps * fix for alpine * Refactor unit-tests script to not using readies WIP * revert vecsim accidental change * Fix script so it will work for sanitizer as well, address CR --------- Co-authored-by: DvirDukhan <[email protected]> Co-authored-by: GuyAv46 <[email protected]> * Wrongly included the text of GPLv3 instead of AGPLv3 (#6089) * README.md - added no standalone released note (#6074) * Update README.md * Update README.md * Update README.md * small change to opcounter * debug command for yield counter + test * add config test * Update SECURITY.md (#6070) * Update SECURITY.md * Update SECURITY.md * Enforce license headers for Rust files (#6090) * A small binary to enforce license headers in all Rust files * Enforce license headers in CI * MOD-6151: Build without readies - simplify packing (#5908) * fix * change ramp version * fix macos * GHA3 * fix macos * fix maxos * fix * fix * fix * new * purge readies * double * typo * remove debug * shapshot * gp * go conflict * darwin to macos * Account for get-platform change, remove redundant mkdir, remove not used/used once variables * remove unused DEP_NAMES * remove unused function * remove un condition * improve pack_ramp * remove unused DEPS * macos * remove xtx * replace eprint * remove runn * replace realapth * Revert "remove xtx" This reverts commit 6efb895. * try remove xtx * remove NOP * remove NUMVER * without tmp * delete * remove eval * remove release * Assume SNAPSHOT=1 * remove SEMVER * fin * remove sbin/getver * Don't add unnecessary \n after the license header (#6095) Otherwise, `cargo fmt` fails on them. * [MOD-9547] Core trie iterators (#6016) * Basic iterators * Typo * Clean up API * Add tests for iterators * More comments * Fix warning for miri * Verify that all prefixed iterators agree with each other and match expectations * Test both lending and non-lending traversals * Clarify comment * Test the empty key case * Fix where bounds on traversal_filter * Add missing license headers * SSPLv1.txt - removed irrelevant text (#6097) * MOD-9612: Fix flaky test and change early timeout error message (#6100) * Fix flaky test AND change early timeout error message * Fix TimeLimit initialization * Add comment * remove deps changes * remove deps changes * fix a possibly new flaky test * temp fix for config * changes to use the config_cmd func * try to fix issue test * use cluster conn in test * handle num of yield with cluster * dont test with cluster * pr changes * move whitespace * add tag and geoshape idx * pr changes * changes to yield only while server is loading * and check if module function exist * remove white space * add wait_for_index in test * pr change rename config * change help text * add isLoading argument * check globally if loading with g_isLoading * pr change --------- Co-authored-by: Luca Palmieri <[email protected]> Co-authored-by: Tim Janus <[email protected]> Co-authored-by: lerman25 <[email protected]> Co-authored-by: alonre24 <[email protected]> Co-authored-by: DvirDukhan <[email protected]> Co-authored-by: GuyAv46 <[email protected]> Co-authored-by: Lior Kogan <[email protected]> Co-authored-by: Zeeshan Ali Khan <[email protected]> Co-authored-by: Raz Monsonego <[email protected]> * change config setters and getters * rename cluster_timeout * [MOD-9372 , MOD-9733] Stop indexing OOM - Add wait before OOM (#6114) * Add config * insert oom_scan field to scanner, remove check for oom in debug pause on oom * fix comment * create basis for function * handle last scanned key * change sleep function name * Add pause before and after reset * Add pause before and after statuses code * Add pause before and after reset to bg scan * wait if config >0 * adjust default sleep time * fix last scanned key * temp tests * bsaic test strcuture * styling * Add scanner status strings * Add first test * Add update option for dbug scanner and more tests * remove scanner cancleation * Alter and Drop tests * spellcheck * skip cluster in tests * Add config test for new config * shortern tests * styling * remove pause on OOM from drop test * Add tests, style * style * style * Remove unused pause after OOM reset * debug commands tests and cluster tests * Naming, styling, formatting * rename, change structure for simplicity * improve test robustness * remove unused and move to better location * Ben comments round1 * Add 0 thresh test * comment * ADd skip cluster * change config and other Alon's comments * small tess * remove pause after Remove duplicates in tests * more test compression * fix assert * pr changes * remove unwanted changes * dont change 'search-conn-per-shard' to max value, because it causes the test to be flaky * change 'search-conn-per-shard' maxvalue in test * change 'search-conn-per-shard' maxvalue in test --------- Co-authored-by: Zeeshan Ali Khan <[email protected]> Co-authored-by: Luca Palmieri <[email protected]> Co-authored-by: meiravgri <[email protected]> Co-authored-by: GuyAv46 <[email protected]> Co-authored-by: nafraf <[email protected]> Co-authored-by: redisearch-backport-pull-request[bot] <182669528+redisearch-backport-pull-request[bot]@users.noreply.github.com> Co-authored-by: alonre24 <[email protected]> Co-authored-by: lerman25 <[email protected]> Co-authored-by: kei-nan <[email protected]> Co-authored-by: Joan Fontanals <[email protected]> Co-authored-by: Tim Janus <[email protected]> Co-authored-by: DvirDukhan <[email protected]> Co-authored-by: GuyAv46 <[email protected]> Co-authored-by: Lior Kogan <[email protected]> Co-authored-by: Raz Monsonego <[email protected]>
* test config set doesnt effect other configs * change config setters and getters * handle isInverted * fix partial indexes tests * rename cluster_timeout * fix py test * refactor tests * mll change to test * Some cargo clippy fixes (#6122) Clippy fixes * Use the correct Rust profile for every task (#6128) * Compute coverage for Rust tests in CI (#6127) * restore macos-latest-xlarge (#6132) * CI - update release flow - [MOD-9681] (#6131) * change release flow to be triggered by a tag push * TEMP call this branch 3.2.1 * dummy content * fix branch validation * improve error message * revert temporary changes * improve message * [MOD-9694] Trie prefixes iterator (#6119) * Prefixes iterator * Align with C: do not track keys in the prefixes iterator * Compile arr.h as a standalone static library * Fix memory issue in bench * Add license header * Re-add tests for values iterator * Add another prefix benchmark using the full Gutenberg dataset. * [MOD-9693] IntoValues trie iterator. (#6129) IntoValues iterator * rockylinux:8 install python3.12 packages (#6147) rockylinux:8 install python3.12-devel * Fix linting failure on Rust LowMemoryThinVec drop implementation (#6146) replace `mem::replace` with `mem::take` * [master] [8.0] Remove -Werror linker flags [MOD-9624] (#6105) [8.0] Remove -Werror linker flags [MOD-9624] (#6104) * remove linker flag -werror * remove linker flag -werror - one more (cherry picked from commit 5688fcc) Co-authored-by: alonre24 <[email protected]> * Coverage Report Without `readies` - Phase 2 - [MOD-6711] (#5909) * WIP new coverage flow * move coverage logic to task-test.yml and build.sh * type change and rust test fixes * comment-out run_miri input * minor fixes and improvements * update file paths * fix build for coverage * remove redundancy * fix redis build * fix command * another attempt * fix * run against latest redis * fix coordinator env vars * add missing rust tests * don't run rust tests on sanitizer (for now) * attempt to fix coverage capture * attempt to fix rust sanitizer * attempt to fix the rust test instead * replace single quotes with double quotes * improve prints * remove quotes * attempt to fix unit-test paths * debug build on coverage * cleanups * Revert "MOD-8391: Report active threads-indexes upon crash (#5403)" This reverts commit 384a2f6. * Reapply "MOD-8391: Report active threads-indexes upon crash (#5403)" This reverts commit ed38b62. * better capture * add a tests extraction step for a unified flow in older versions * fix step to allow no-op * CI Improvements (#6153) * improvements * use job-based concurrency * notify benchmark failure only on push * improve job name * test notification * skip actual benchamrks * Revert "skip actual benchamrks" This reverts commit 59e8fb2. * Revert "test notification" This reverts commit 1661e0a. * re-implement notification condition with input * test * Revert "test" This reverts commit 80206ae. * cleanup * test recent changes * change and test * fix * cleanup * fixes * Add .cache to git ignore list (#6157) Seems clang creates a cache under this directory, so let's put it to git ignore list. * Remove base64 code from codebase (#6161) remove base64 code * [MOD-9372 , MOD-9733] Stop indexing OOM - Add wait before OOM (#6114) * Add config * insert oom_scan field to scanner, remove check for oom in debug pause on oom * fix comment * create basis for function * handle last scanned key * change sleep function name * Add pause before and after reset * Add pause before and after statuses code * Add pause before and after reset to bg scan * wait if config >0 * adjust default sleep time * fix last scanned key * temp tests * bsaic test strcuture * styling * Add scanner status strings * Add first test * Add update option for dbug scanner and more tests * remove scanner cancleation * Alter and Drop tests * spellcheck * skip cluster in tests * Add config test for new config * shortern tests * styling * remove pause on OOM from drop test * Add tests, style * style * style * Remove unused pause after OOM reset * debug commands tests and cluster tests * Naming, styling, formatting * rename, change structure for simplicity * improve test robustness * remove unused and move to better location * Ben comments round1 * Add 0 thresh test * comment * ADd skip cluster * change config and other Alon's comments * small tess * remove pause after Remove duplicates in tests * more test compression * fix assert * Temp disable coverage as required for CI to pass in PRs (#6166) temp to allow PRs * [MOD-9735] Track the number of unique keys in the trie. (#6156) Track the number of unique keys in the trie. * [MOD-9692] Wildcard trie iterator. (#6130) Wildcard trie iterator * Fix micro-benchmarking job on master branch (#6162) Fix workspace benching * Use the correct profile name for Rust debug builds (#6170) * Add More Diagnostics When Active Queries Are Not Empty (#6167) * initial commit * Apply suggestions from code review Co-authored-by: GuyAv46 <[email protected]> * code review comments * output the explain string for queries if hide user data from logs is off when dumping queries * fix typo * free allocated query string --------- Co-authored-by: GuyAv46 <[email protected]> * [MOD-9372 , MOD-9733] Stop indexing OOM - Add wait before OOM (#6114) * Add config * insert oom_scan field to scanner, remove check for oom in debug pause on oom * fix comment * create basis for function * handle last scanned key * change sleep function name * Add pause before and after reset * Add pause before and after statuses code * Add pause before and after reset to bg scan * wait if config >0 * adjust default sleep time * fix last scanned key * temp tests * bsaic test strcuture * styling * Add scanner status strings * Add first test * Add update option for dbug scanner and more tests * remove scanner cancleation * Alter and Drop tests * spellcheck * skip cluster in tests * Add config test for new config * shortern tests * styling * remove pause on OOM from drop test * Add tests, style * style * style * Remove unused pause after OOM reset * debug commands tests and cluster tests * Naming, styling, formatting * rename, change structure for simplicity * improve test robustness * remove unused and move to better location * Ben comments round1 * Add 0 thresh test * comment * ADd skip cluster * change config and other Alon's comments * small tess * remove pause after Remove duplicates in tests * more test compression * fix assert * mention BM25 as default scorer in README (#6165) * Yield to redis while indexing - [MOD-9220] (#6103) * add op-counter + config * Run all Rust benchmarks in the workspace (#6030) * Run all Rust benchmarks in the workspace * Allow forcing the run for micro-benchmarks * Fix bench run * Update .github/workflows/flow-micro-benchmarks.yml Co-authored-by: Tim Janus <[email protected]> --------- Co-authored-by: Tim Janus <[email protected]> * Fix Rust build after switching off readies (#6086) Fix Rust linking * [MOD-9560] Change default config value for _BG_INDEX_MEM_PCT_THR (#6053) * change default value * change default value in config pytest * change index oom tests to lower value then new default * change debug commands tests to lower value then default value * change default value of set tight memory functions * 100testv1 * test default value * Build unit tests without readies [MOD-9099] (#6082) * purge readeis from cmake. Use new build script instead of makefile * call script in CI * libuv * restore build folder * libuv * unit tests * pretty build.sh * pytest * fixed extension build error * Add profile flags + try pass linker flag properly (wip) * fix build and linkage + pytest + adjust json * small cleanup * Add pytz dep * bump googletest version, use same variant name as before * remove ld libs * Fix executable linker flags - build unit test properly. run unit tests with old "make unit-tests" way (until this is fixed via ./build.sh) * fix rust build via build.sh * fix san build * Set coverage flags and use the same bin dir for sanitizer (build it for debug) * update benchmark image for regression test * remove leftover * Build hiredis static * fix json env flag in CI * CR changes * Restore deleted files until unit tests are done as well, use boolean params * restore vecsim version * fix profile and fix build error * fix for profile * try fix mac build * fix unit tests for arm * Define boost dir * remove the policies * try fix the binroot for unit-tests * change dir name for arm * remove policy from hash as well * use clang in mac * try to set hardcoded clang * try to mimic readies in macos includes * try set CMAKE_OSX_DEPLOYMENT_TARGET * whitespace formatting * Set CC to clang in apple * try to export llvm * try set compiler in build script * use bin in path * try EXPORT properly with homebrew * remove setting bad path to clang * set clang path * update to llvm@18 * update c++ path * set compiler with LLVM env var * fix? * set proper link flags for mac * remove bsymbolic from hiredis * revert hiredis in non macos to how it was * clean stuff * cleanups * Fix the extract debug symbols command so it will work as before (required for packing properly) * update deps * fix for alpine * Refactor unit-tests script to not using readies WIP * revert vecsim accidental change * Fix script so it will work for sanitizer as well, address CR --------- Co-authored-by: DvirDukhan <[email protected]> Co-authored-by: GuyAv46 <[email protected]> * Wrongly included the text of GPLv3 instead of AGPLv3 (#6089) * README.md - added no standalone released note (#6074) * Update README.md * Update README.md * Update README.md * small change to opcounter * debug command for yield counter + test * add config test * Update SECURITY.md (#6070) * Update SECURITY.md * Update SECURITY.md * Enforce license headers for Rust files (#6090) * A small binary to enforce license headers in all Rust files * Enforce license headers in CI * MOD-6151: Build without readies - simplify packing (#5908) * fix * change ramp version * fix macos * GHA3 * fix macos * fix maxos * fix * fix * fix * new * purge readies * double * typo * remove debug * shapshot * gp * go conflict * darwin to macos * Account for get-platform change, remove redundant mkdir, remove not used/used once variables * remove unused DEP_NAMES * remove unused function * remove un condition * improve pack_ramp * remove unused DEPS * macos * remove xtx * replace eprint * remove runn * replace realapth * Revert "remove xtx" This reverts commit 6efb895. * try remove xtx * remove NOP * remove NUMVER * without tmp * delete * remove eval * remove release * Assume SNAPSHOT=1 * remove SEMVER * fin * remove sbin/getver * Don't add unnecessary \n after the license header (#6095) Otherwise, `cargo fmt` fails on them. * [MOD-9547] Core trie iterators (#6016) * Basic iterators * Typo * Clean up API * Add tests for iterators * More comments * Fix warning for miri * Verify that all prefixed iterators agree with each other and match expectations * Test both lending and non-lending traversals * Clarify comment * Test the empty key case * Fix where bounds on traversal_filter * Add missing license headers * SSPLv1.txt - removed irrelevant text (#6097) * MOD-9612: Fix flaky test and change early timeout error message (#6100) * Fix flaky test AND change early timeout error message * Fix TimeLimit initialization * Add comment * remove deps changes * remove deps changes * fix a possibly new flaky test * temp fix for config * changes to use the config_cmd func * try to fix issue test * use cluster conn in test * handle num of yield with cluster * dont test with cluster * pr changes * move whitespace * add tag and geoshape idx * pr changes * changes to yield only while server is loading * and check if module function exist * remove white space * add wait_for_index in test * pr change rename config * change help text * add isLoading argument * check globally if loading with g_isLoading * pr change --------- Co-authored-by: Luca Palmieri <[email protected]> Co-authored-by: Tim Janus <[email protected]> Co-authored-by: lerman25 <[email protected]> Co-authored-by: alonre24 <[email protected]> Co-authored-by: DvirDukhan <[email protected]> Co-authored-by: GuyAv46 <[email protected]> Co-authored-by: Lior Kogan <[email protected]> Co-authored-by: Zeeshan Ali Khan <[email protected]> Co-authored-by: Raz Monsonego <[email protected]> * change config setters and getters * rename cluster_timeout * [MOD-9372 , MOD-9733] Stop indexing OOM - Add wait before OOM (#6114) * Add config * insert oom_scan field to scanner, remove check for oom in debug pause on oom * fix comment * create basis for function * handle last scanned key * change sleep function name * Add pause before and after reset * Add pause before and after statuses code * Add pause before and after reset to bg scan * wait if config >0 * adjust default sleep time * fix last scanned key * temp tests * bsaic test strcuture * styling * Add scanner status strings * Add first test * Add update option for dbug scanner and more tests * remove scanner cancleation * Alter and Drop tests * spellcheck * skip cluster in tests * Add config test for new config * shortern tests * styling * remove pause on OOM from drop test * Add tests, style * style * style * Remove unused pause after OOM reset * debug commands tests and cluster tests * Naming, styling, formatting * rename, change structure for simplicity * improve test robustness * remove unused and move to better location * Ben comments round1 * Add 0 thresh test * comment * ADd skip cluster * change config and other Alon's comments * small tess * remove pause after Remove duplicates in tests * more test compression * fix assert * pr changes * remove unwanted changes * dont change 'search-conn-per-shard' to max value, because it causes the test to be flaky * change 'search-conn-per-shard' maxvalue in test * change 'search-conn-per-shard' maxvalue in test --------- Co-authored-by: Zeeshan Ali Khan <[email protected]> Co-authored-by: Luca Palmieri <[email protected]> Co-authored-by: meiravgri <[email protected]> Co-authored-by: GuyAv46 <[email protected]> Co-authored-by: nafraf <[email protected]> Co-authored-by: redisearch-backport-pull-request[bot] <182669528+redisearch-backport-pull-request[bot]@users.noreply.github.com> Co-authored-by: alonre24 <[email protected]> Co-authored-by: lerman25 <[email protected]> Co-authored-by: kei-nan <[email protected]> Co-authored-by: Joan Fontanals <[email protected]> Co-authored-by: Tim Janus <[email protected]> Co-authored-by: DvirDukhan <[email protected]> Co-authored-by: GuyAv46 <[email protected]> Co-authored-by: Lior Kogan <[email protected]> Co-authored-by: Raz Monsonego <[email protected]> (cherry picked from commit fc03b3e)
change config setters and getters - [MOD-9673] (#6151) * test config set doesnt effect other configs * change config setters and getters * handle isInverted * fix partial indexes tests * rename cluster_timeout * fix py test * refactor tests * mll change to test * Some cargo clippy fixes (#6122) Clippy fixes * Use the correct Rust profile for every task (#6128) * Compute coverage for Rust tests in CI (#6127) * restore macos-latest-xlarge (#6132) * CI - update release flow - [MOD-9681] (#6131) * change release flow to be triggered by a tag push * TEMP call this branch 3.2.1 * dummy content * fix branch validation * improve error message * revert temporary changes * improve message * [MOD-9694] Trie prefixes iterator (#6119) * Prefixes iterator * Align with C: do not track keys in the prefixes iterator * Compile arr.h as a standalone static library * Fix memory issue in bench * Add license header * Re-add tests for values iterator * Add another prefix benchmark using the full Gutenberg dataset. * [MOD-9693] IntoValues trie iterator. (#6129) IntoValues iterator * rockylinux:8 install python3.12 packages (#6147) rockylinux:8 install python3.12-devel * Fix linting failure on Rust LowMemoryThinVec drop implementation (#6146) replace `mem::replace` with `mem::take` * [master] [8.0] Remove -Werror linker flags [MOD-9624] (#6105) [8.0] Remove -Werror linker flags [MOD-9624] (#6104) * remove linker flag -werror * remove linker flag -werror - one more (cherry picked from commit 5688fcc) * Coverage Report Without `readies` - Phase 2 - [MOD-6711] (#5909) * WIP new coverage flow * move coverage logic to task-test.yml and build.sh * type change and rust test fixes * comment-out run_miri input * minor fixes and improvements * update file paths * fix build for coverage * remove redundancy * fix redis build * fix command * another attempt * fix * run against latest redis * fix coordinator env vars * add missing rust tests * don't run rust tests on sanitizer (for now) * attempt to fix coverage capture * attempt to fix rust sanitizer * attempt to fix the rust test instead * replace single quotes with double quotes * improve prints * remove quotes * attempt to fix unit-test paths * debug build on coverage * cleanups * Revert "MOD-8391: Report active threads-indexes upon crash (#5403)" This reverts commit 384a2f6. * Reapply "MOD-8391: Report active threads-indexes upon crash (#5403)" This reverts commit ed38b62. * better capture * add a tests extraction step for a unified flow in older versions * fix step to allow no-op * CI Improvements (#6153) * improvements * use job-based concurrency * notify benchmark failure only on push * improve job name * test notification * skip actual benchamrks * Revert "skip actual benchamrks" This reverts commit 59e8fb2. * Revert "test notification" This reverts commit 1661e0a. * re-implement notification condition with input * test * Revert "test" This reverts commit 80206ae. * cleanup * test recent changes * change and test * fix * cleanup * fixes * Add .cache to git ignore list (#6157) Seems clang creates a cache under this directory, so let's put it to git ignore list. * Remove base64 code from codebase (#6161) remove base64 code * [MOD-9372 , MOD-9733] Stop indexing OOM - Add wait before OOM (#6114) * Add config * insert oom_scan field to scanner, remove check for oom in debug pause on oom * fix comment * create basis for function * handle last scanned key * change sleep function name * Add pause before and after reset * Add pause before and after statuses code * Add pause before and after reset to bg scan * wait if config >0 * adjust default sleep time * fix last scanned key * temp tests * bsaic test strcuture * styling * Add scanner status strings * Add first test * Add update option for dbug scanner and more tests * remove scanner cancleation * Alter and Drop tests * spellcheck * skip cluster in tests * Add config test for new config * shortern tests * styling * remove pause on OOM from drop test * Add tests, style * style * style * Remove unused pause after OOM reset * debug commands tests and cluster tests * Naming, styling, formatting * rename, change structure for simplicity * improve test robustness * remove unused and move to better location * Ben comments round1 * Add 0 thresh test * comment * ADd skip cluster * change config and other Alon's comments * small tess * remove pause after Remove duplicates in tests * more test compression * fix assert * Temp disable coverage as required for CI to pass in PRs (#6166) temp to allow PRs * [MOD-9735] Track the number of unique keys in the trie. (#6156) Track the number of unique keys in the trie. * [MOD-9692] Wildcard trie iterator. (#6130) Wildcard trie iterator * Fix micro-benchmarking job on master branch (#6162) Fix workspace benching * Use the correct profile name for Rust debug builds (#6170) * Add More Diagnostics When Active Queries Are Not Empty (#6167) * initial commit * Apply suggestions from code review * code review comments * output the explain string for queries if hide user data from logs is off when dumping queries * fix typo * free allocated query string --------- * [MOD-9372 , MOD-9733] Stop indexing OOM - Add wait before OOM (#6114) * Add config * insert oom_scan field to scanner, remove check for oom in debug pause on oom * fix comment * create basis for function * handle last scanned key * change sleep function name * Add pause before and after reset * Add pause before and after statuses code * Add pause before and after reset to bg scan * wait if config >0 * adjust default sleep time * fix last scanned key * temp tests * bsaic test strcuture * styling * Add scanner status strings * Add first test * Add update option for dbug scanner and more tests * remove scanner cancleation * Alter and Drop tests * spellcheck * skip cluster in tests * Add config test for new config * shortern tests * styling * remove pause on OOM from drop test * Add tests, style * style * style * Remove unused pause after OOM reset * debug commands tests and cluster tests * Naming, styling, formatting * rename, change structure for simplicity * improve test robustness * remove unused and move to better location * Ben comments round1 * Add 0 thresh test * comment * ADd skip cluster * change config and other Alon's comments * small tess * remove pause after Remove duplicates in tests * more test compression * fix assert * mention BM25 as default scorer in README (#6165) * Yield to redis while indexing - [MOD-9220] (#6103) * add op-counter + config * Run all Rust benchmarks in the workspace (#6030) * Run all Rust benchmarks in the workspace * Allow forcing the run for micro-benchmarks * Fix bench run * Update .github/workflows/flow-micro-benchmarks.yml --------- * Fix Rust build after switching off readies (#6086) Fix Rust linking * [MOD-9560] Change default config value for _BG_INDEX_MEM_PCT_THR (#6053) * change default value * change default value in config pytest * change index oom tests to lower value then new default * change debug commands tests to lower value then default value * change default value of set tight memory functions * 100testv1 * test default value * Build unit tests without readies [MOD-9099] (#6082) * purge readeis from cmake. Use new build script instead of makefile * call script in CI * libuv * restore build folder * libuv * unit tests * pretty build.sh * pytest * fixed extension build error * Add profile flags + try pass linker flag properly (wip) * fix build and linkage + pytest + adjust json * small cleanup * Add pytz dep * bump googletest version, use same variant name as before * remove ld libs * Fix executable linker flags - build unit test properly. run unit tests with old "make unit-tests" way (until this is fixed via ./build.sh) * fix rust build via build.sh * fix san build * Set coverage flags and use the same bin dir for sanitizer (build it for debug) * update benchmark image for regression test * remove leftover * Build hiredis static * fix json env flag in CI * CR changes * Restore deleted files until unit tests are done as well, use boolean params * restore vecsim version * fix profile and fix build error * fix for profile * try fix mac build * fix unit tests for arm * Define boost dir * remove the policies * try fix the binroot for unit-tests * change dir name for arm * remove policy from hash as well * use clang in mac * try to set hardcoded clang * try to mimic readies in macos includes * try set CMAKE_OSX_DEPLOYMENT_TARGET * whitespace formatting * Set CC to clang in apple * try to export llvm * try set compiler in build script * use bin in path * try EXPORT properly with homebrew * remove setting bad path to clang * set clang path * update to llvm@18 * update c++ path * set compiler with LLVM env var * fix? * set proper link flags for mac * remove bsymbolic from hiredis * revert hiredis in non macos to how it was * clean stuff * cleanups * Fix the extract debug symbols command so it will work as before (required for packing properly) * update deps * fix for alpine * Refactor unit-tests script to not using readies WIP * revert vecsim accidental change * Fix script so it will work for sanitizer as well, address CR --------- * Wrongly included the text of GPLv3 instead of AGPLv3 (#6089) * README.md - added no standalone released note (#6074) * Update README.md * Update README.md * Update README.md * small change to opcounter * debug command for yield counter + test * add config test * Update SECURITY.md (#6070) * Update SECURITY.md * Update SECURITY.md * Enforce license headers for Rust files (#6090) * A small binary to enforce license headers in all Rust files * Enforce license headers in CI * MOD-6151: Build without readies - simplify packing (#5908) * fix * change ramp version * fix macos * GHA3 * fix macos * fix maxos * fix * fix * fix * new * purge readies * double * typo * remove debug * shapshot * gp * go conflict * darwin to macos * Account for get-platform change, remove redundant mkdir, remove not used/used once variables * remove unused DEP_NAMES * remove unused function * remove un condition * improve pack_ramp * remove unused DEPS * macos * remove xtx * replace eprint * remove runn * replace realapth * Revert "remove xtx" This reverts commit 6efb895. * try remove xtx * remove NOP * remove NUMVER * without tmp * delete * remove eval * remove release * Assume SNAPSHOT=1 * remove SEMVER * fin * remove sbin/getver * Don't add unnecessary \n after the license header (#6095) Otherwise, `cargo fmt` fails on them. * [MOD-9547] Core trie iterators (#6016) * Basic iterators * Typo * Clean up API * Add tests for iterators * More comments * Fix warning for miri * Verify that all prefixed iterators agree with each other and match expectations * Test both lending and non-lending traversals * Clarify comment * Test the empty key case * Fix where bounds on traversal_filter * Add missing license headers * SSPLv1.txt - removed irrelevant text (#6097) * MOD-9612: Fix flaky test and change early timeout error message (#6100) * Fix flaky test AND change early timeout error message * Fix TimeLimit initialization * Add comment * remove deps changes * remove deps changes * fix a possibly new flaky test * temp fix for config * changes to use the config_cmd func * try to fix issue test * use cluster conn in test * handle num of yield with cluster * dont test with cluster * pr changes * move whitespace * add tag and geoshape idx * pr changes * changes to yield only while server is loading * and check if module function exist * remove white space * add wait_for_index in test * pr change rename config * change help text * add isLoading argument * check globally if loading with g_isLoading * pr change --------- * change config setters and getters * rename cluster_timeout * [MOD-9372 , MOD-9733] Stop indexing OOM - Add wait before OOM (#6114) * Add config * insert oom_scan field to scanner, remove check for oom in debug pause on oom * fix comment * create basis for function * handle last scanned key * change sleep function name * Add pause before and after reset * Add pause before and after statuses code * Add pause before and after reset to bg scan * wait if config >0 * adjust default sleep time * fix last scanned key * temp tests * bsaic test strcuture * styling * Add scanner status strings * Add first test * Add update option for dbug scanner and more tests * remove scanner cancleation * Alter and Drop tests * spellcheck * skip cluster in tests * Add config test for new config * shortern tests * styling * remove pause on OOM from drop test * Add tests, style * style * style * Remove unused pause after OOM reset * debug commands tests and cluster tests * Naming, styling, formatting * rename, change structure for simplicity * improve test robustness * remove unused and move to better location * Ben comments round1 * Add 0 thresh test * comment * ADd skip cluster * change config and other Alon's comments * small tess * remove pause after Remove duplicates in tests * more test compression * fix assert * pr changes * remove unwanted changes * dont change 'search-conn-per-shard' to max value, because it causes the test to be flaky * change 'search-conn-per-shard' maxvalue in test * change 'search-conn-per-shard' maxvalue in test --------- (cherry picked from commit fc03b3e) Co-authored-by: Zeeshan Ali Khan <[email protected]> Co-authored-by: Luca Palmieri <[email protected]> Co-authored-by: meiravgri <[email protected]> Co-authored-by: GuyAv46 <[email protected]> Co-authored-by: nafraf <[email protected]> Co-authored-by: redisearch-backport-pull-request[bot] <182669528+redisearch-backport-pull-request[bot]@users.noreply.github.com> Co-authored-by: alonre24 <[email protected]> Co-authored-by: lerman25 <[email protected]> Co-authored-by: kei-nan <[email protected]> Co-authored-by: Joan Fontanals <[email protected]> Co-authored-by: Tim Janus <[email protected]> Co-authored-by: DvirDukhan <[email protected]> Co-authored-by: GuyAv46 <[email protected]> Co-authored-by: Lior Kogan <[email protected]> Co-authored-by: Raz Monsonego <[email protected]>
* WIP new coverage flow * move coverage logic to task-test.yml and build.sh * type change and rust test fixes * comment-out run_miri input * minor fixes and improvements * update file paths * fix build for coverage * remove redundancy * fix redis build * fix command * another attempt * fix * run against latest redis * fix coordinator env vars * add missing rust tests * don't run rust tests on sanitizer (for now) * attempt to fix coverage capture * attempt to fix rust sanitizer * attempt to fix the rust test instead * replace single quotes with double quotes * improve prints * remove quotes * attempt to fix unit-test paths * debug build on coverage * cleanups * Revert "MOD-8391: Report active threads-indexes upon crash (#5403)" This reverts commit 384a2f6. * Reapply "MOD-8391: Report active threads-indexes upon crash (#5403)" This reverts commit ed38b62. * better capture * add a tests extraction step for a unified flow in older versions * fix step to allow no-op (cherry picked from commit fd8ce73)
Coverage Report Without `readies` - Phase 2 - [MOD-6711] (#5909) * WIP new coverage flow * move coverage logic to task-test.yml and build.sh * type change and rust test fixes * comment-out run_miri input * minor fixes and improvements * update file paths * fix build for coverage * remove redundancy * fix redis build * fix command * another attempt * fix * run against latest redis * fix coordinator env vars * add missing rust tests * don't run rust tests on sanitizer (for now) * attempt to fix coverage capture * attempt to fix rust sanitizer * attempt to fix the rust test instead * replace single quotes with double quotes * improve prints * remove quotes * attempt to fix unit-test paths * debug build on coverage * cleanups * Revert "MOD-8391: Report active threads-indexes upon crash (#5403)" This reverts commit 384a2f6. * Reapply "MOD-8391: Report active threads-indexes upon crash (#5403)" This reverts commit ed38b62. * better capture * add a tests extraction step for a unified flow in older versions * fix step to allow no-op (cherry picked from commit fd8ce73)
* WIP new coverage flow * move coverage logic to task-test.yml and build.sh * type change and rust test fixes * comment-out run_miri input * minor fixes and improvements * update file paths * fix build for coverage * remove redundancy * fix redis build * fix command * another attempt * fix * run against latest redis * fix coordinator env vars * add missing rust tests * don't run rust tests on sanitizer (for now) * attempt to fix coverage capture * attempt to fix rust sanitizer * attempt to fix the rust test instead * replace single quotes with double quotes * improve prints * remove quotes * attempt to fix unit-test paths * debug build on coverage * cleanups * Revert "MOD-8391: Report active threads-indexes upon crash (#5403)" This reverts commit 384a2f6. * Reapply "MOD-8391: Report active threads-indexes upon crash (#5403)" This reverts commit ed38b62. * better capture * add a tests extraction step for a unified flow in older versions * fix step to allow no-op (cherry picked from commit fd8ce73)
* WIP new coverage flow * move coverage logic to task-test.yml and build.sh * type change and rust test fixes * comment-out run_miri input * minor fixes and improvements * update file paths * fix build for coverage * remove redundancy * fix redis build * fix command * another attempt * fix * run against latest redis * fix coordinator env vars * add missing rust tests * don't run rust tests on sanitizer (for now) * attempt to fix coverage capture * attempt to fix rust sanitizer * attempt to fix the rust test instead * replace single quotes with double quotes * improve prints * remove quotes * attempt to fix unit-test paths * debug build on coverage * cleanups * Revert "MOD-8391: Report active threads-indexes upon crash (#5403)" This reverts commit 384a2f6. * Reapply "MOD-8391: Report active threads-indexes upon crash (#5403)" This reverts commit ed38b62. * better capture * add a tests extraction step for a unified flow in older versions * fix step to allow no-op (cherry picked from commit fd8ce73)
* WIP new coverage flow * move coverage logic to task-test.yml and build.sh * type change and rust test fixes * comment-out run_miri input * minor fixes and improvements * update file paths * fix build for coverage * remove redundancy * fix redis build * fix command * another attempt * fix * run against latest redis * fix coordinator env vars * add missing rust tests * don't run rust tests on sanitizer (for now) * attempt to fix coverage capture * attempt to fix rust sanitizer * attempt to fix the rust test instead * replace single quotes with double quotes * improve prints * remove quotes * attempt to fix unit-test paths * debug build on coverage * cleanups * Revert "MOD-8391: Report active threads-indexes upon crash (#5403)" This reverts commit 384a2f6. * Reapply "MOD-8391: Report active threads-indexes upon crash (#5403)" This reverts commit ed38b62. * better capture * add a tests extraction step for a unified flow in older versions * fix step to allow no-op (cherry picked from commit fd8ce73)
* Coverage Report Without `readies` - Phase 2 - [MOD-6711] (#5909) * WIP new coverage flow * move coverage logic to task-test.yml and build.sh * type change and rust test fixes * comment-out run_miri input * minor fixes and improvements * update file paths * fix build for coverage * remove redundancy * fix redis build * fix command * another attempt * fix * run against latest redis * fix coordinator env vars * add missing rust tests * don't run rust tests on sanitizer (for now) * attempt to fix coverage capture * attempt to fix rust sanitizer * attempt to fix the rust test instead * replace single quotes with double quotes * improve prints * remove quotes * attempt to fix unit-test paths * debug build on coverage * cleanups * Revert "MOD-8391: Report active threads-indexes upon crash (#5403)" This reverts commit 384a2f6. * Reapply "MOD-8391: Report active threads-indexes upon crash (#5403)" This reverts commit ed38b62. * better capture * add a tests extraction step for a unified flow in older versions * fix step to allow no-op (cherry picked from commit fd8ce73) * change default env for 2.8 (cherry picked from commit 51e4a81) * revert to ubuntu latest for sanitizer * add coord root dir to coverage report whitelist * use ubuntu24 * --ignore-errors mismatch
* Coverage Report Without `readies` - Phase 2 - [MOD-6711] (#5909) * WIP new coverage flow * move coverage logic to task-test.yml and build.sh * type change and rust test fixes * comment-out run_miri input * minor fixes and improvements * update file paths * fix build for coverage * remove redundancy * fix redis build * fix command * another attempt * fix * run against latest redis * fix coordinator env vars * add missing rust tests * don't run rust tests on sanitizer (for now) * attempt to fix coverage capture * attempt to fix rust sanitizer * attempt to fix the rust test instead * replace single quotes with double quotes * improve prints * remove quotes * attempt to fix unit-test paths * debug build on coverage * cleanups * Revert "MOD-8391: Report active threads-indexes upon crash (#5403)" This reverts commit 384a2f6. * Reapply "MOD-8391: Report active threads-indexes upon crash (#5403)" This reverts commit ed38b62. * better capture * add a tests extraction step for a unified flow in older versions * fix step to allow no-op (cherry picked from commit fd8ce73) * change default env for 2.6 (cherry picked from commit 51e4a81) * delete installation file * revert to ubuntu latest for sanitizer * add coord root dir to coverage report whitelist * fix unit tests coverage report file name * use ubuntu-24.04 * fix 2.6 issue * another naming fix
* Coverage Report Without `readies` - Phase 2 - [MOD-6711] (#5909) * WIP new coverage flow * move coverage logic to task-test.yml and build.sh * type change and rust test fixes * comment-out run_miri input * minor fixes and improvements * update file paths * fix build for coverage * remove redundancy * fix redis build * fix command * another attempt * fix * run against latest redis * fix coordinator env vars * add missing rust tests * don't run rust tests on sanitizer (for now) * attempt to fix coverage capture * attempt to fix rust sanitizer * attempt to fix the rust test instead * replace single quotes with double quotes * improve prints * remove quotes * attempt to fix unit-test paths * debug build on coverage * cleanups * Revert "MOD-8391: Report active threads-indexes upon crash (#5403)" This reverts commit 384a2f6. * Reapply "MOD-8391: Report active threads-indexes upon crash (#5403)" This reverts commit ed38b62. * better capture * add a tests extraction step for a unified flow in older versions * fix step to allow no-op (cherry picked from commit fd8ce73) * small improvement * change default env for 2.10 * revert to ubuntu latest for sanitizer * add coord root dir to coverage report whitelist * use ubuntu24 * --ignore-errors mismatch
Describe the changes in the pull request
This PR adds a global container holding a mapping between the active queries and the indexes they are working on, such that we can later add information to the logs in case of a crash (more use-cases may follow).
We add the thread to the global container for the following flows:
FT.SEARCH/AGGREGATEcommand.FT.CURSOR READcommand.Notice:
FT.INFO,FT.SEARCHcommands. The thread running theFT.CURSORcommand is registered only for theFT.CURSOR READsubcommand.Mark if applicable