Skip to content

Conversation

@tsmith023
Copy link
Collaborator

No description provided.

rlmanrique and others added 12 commits October 16, 2025 11:52
flat index: Add support for RQ and include cache param
#1765)

* Add client-side changes to handle new server-side batching in 1.33

* Update images in CI

* Update 1.33 image in CI

* Alter test or lazy shard loading for new potential server behaviour

* Change other lazy loading test too

* Fix CI image for 1.33

* Update protos, fix setting of batch client in wrapper to avoid races with connection

* Remove debug assert in test

* Update new batch to use different modes with server, update CI image

* Refactor to changed server batching options

* Throw error if using automatic batching with incompatible server

* Add exponential backoff retry to stream reconnect method

* Remove timeout and retries from new grpc methods

* Only delete key if present in dict

* Close before re-connecting, reset rec num objs on shutdown

* Update to use latest protos and behaviour

* Improve logging using .automatic()

* Update CI image to latest server build

* Fix testing issues with new versions

* Attempt fixes for tests again

* Add ability to retry certain server-emitted full errors, e.g. temporary replication problems

* Attempt fixes of flakes

* Update to use latest server impl and CI image

* Update to use latest dev server version

* Rename from automatic to experimental, bump CI version to latest RC

* Push ongoing changes

* Update to use latest server image

* Update to use latest server changes

* Undo debug changes to conftest

* Update to use latest server image

* Make internal send/recv queue size 1 and sleep while shutdown to avoid pushing to it

* Update to use latest server image

* Fix shutting down message handling

* Skip backoff handling if client has closed the stream

* Remove unused code

* Don't print backoff adjustments when shutting down

* Improve shutting down log

* Attempt to catch last req that can be lost during shutdown

* Avoid circular import

* Remove last_req wrapping logic from stream, reduce logging, update image in ci

* Close the client-side of the stream on shutdown, sleep for backoff during req generation

* Update CI image

* Only log waiting for stream re-establishment once

* Switch from arm to amd in CI

* Shutdown client-side stream regardless of size of __reqs queue

* Increase timeout when waiting for req to send, don't use queue size in if due to unreliability

* Use sentinel in req put/get to avoid inaccurate block timeouts

* Update CI image

* Correctly populate batch.results

* Update CI images

* Assert indexing status in one of the allowed values rather than a specific value

* Undo debug changes in tests

* Update to match new server impl

* Update to use latest server image

* Only start threads once to avoid runtime error when handling shutdown

* Update CI images

* Hard-code SSB concurrency to 1 for now

* Fix collection.batch.automatic

* Correct logic in `_BgThreads.is_alive`

* Adjust default batch size to align with server default and avoid overloading server too fast

* Update CI images and version checks in tests

* Update to use latest server behaviour around backoffs and uuid/err results

* Lock once when reading batch results from stream

* Interpret context canceled as ungraceful shutdown to be restarted by client

* Use backoff message to adjust batch size

* Start batching with smallest allowed server value

* Add extra log in batch send

* Reintroduce timeout when getting from queue

* Add log to empty queue

* Add log to batch recv restart

* Remove timeout when getting from internal queue

* Only update batch size if value has changed

* Track then log total number of objects pushed by client

* WIP: receive shutdown as message and not rpc error

* Move result writing inside message.results case

* Add missing proto changes

* Update CI image

* Improve resiliance on unexpected server behaviour

---------

Co-authored-by: Dirk Kulawiak <[email protected]>
Copy link

@orca-security-eu orca-security-eu bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Orca Security Scan Summary

Status Check Issues by priority
Passed Passed Infrastructure as Code high 0   medium 0   low 0   info 0 View in Orca
Passed Passed SAST high 0   medium 0   low 0   info 1 View in Orca
Passed Passed Secrets high 0   medium 0   low 0   info 0 View in Orca
Passed Passed Vulnerabilities high 0   medium 0   low 0   info 0 View in Orca
🛡️ The following SAST misconfigurations have been detected
NAME FILE
info Weak random number generation may compromise cryptographic security ...ing/test_shutdown.py View in code

@codecov-commenter
Copy link

Codecov Report

❌ Patch coverage is 31.30990% with 430 lines in your changes missing coverage. Please review.
✅ Project coverage is 86.80%. Comparing base (a226ea5) to head (2199790).
⚠️ Report is 4 commits behind head on main.

Files with missing lines Patch % Lines
weaviate/collections/batch/base.py 14.95% 273 Missing ⚠️
integration/test_collection_config.py 31.91% 64 Missing ⚠️
weaviate/collections/classes/batch.py 32.14% 19 Missing ⚠️
integration/test_batch_v4.py 50.00% 11 Missing ⚠️
weaviate/connect/v4.py 21.42% 11 Missing ⚠️
integration/test_rbac.py 42.85% 8 Missing ⚠️
weaviate/collections/batch/collection.py 65.21% 8 Missing ⚠️
integration/conftest.py 56.25% 7 Missing ⚠️
weaviate/collections/batch/batch_wrapper.py 77.41% 7 Missing ⚠️
weaviate/collections/batch/client.py 63.15% 7 Missing ⚠️
... and 4 more
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1861      +/-   ##
==========================================
- Coverage   86.86%   86.80%   -0.07%     
==========================================
  Files         273      273              
  Lines       19105    19661     +556     
==========================================
+ Hits        16596    17067     +471     
- Misses       2509     2594      +85     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants