Commit Graph

3 Commits

Author SHA1 Message Date
Tim Visée
1e4ce145a2 Parameterize integration tests (#2375)
* Clean up imports

* Clean up whitespace

* Use drop collection function from helpers

* Use parameterized integration tests to test on_disk variations

* Promote on_disk_vectors parameter into dedicated fixture

* Merge basic retrieve test with parameterization

* Flatten functions

* Split validation test functions

* Don't parameterize on_disk states when testing validation

* Parameterize init_from_collection test sequence

* Parameterize on_disk_payload in tests with fixture

* Parameterize new batch update tests

* Fix integration test collection setup distance after incorrect merge
2023-08-09 12:32:27 +02:00
Luis Cossío
d89d2ec24b Disable indexing and memmap with 0 (#1824)
* feat: use 0 as disable for indexing and memmap

* amend: edit test, update doc comments, remove validation

* fix: use constant instead of literal, reword doc comments

* test: update test for loop and timeout

* fix: remove validation on OptimizerConfigDiff and fix test_validatioin.py

* fix: remove validation from build.rs, remove internal hack from  doccomments

* fix: update grpc docs

* revert max_optimization_threads validation in test

* update config comments and minor test change

---------

Co-authored-by: Andrey Vasnetsov <andrey@vasnetsov.com>
2023-05-05 10:10:35 +02:00
Ivan Pleshkov
4635481492 Add Actix and config validation (#1463)
* actix validation

* add check for memmap/indexing_threshold

* fix actix json settings

* Validate settings configuration on start, print pretty warnings on fail

* Add more validation rules for settings and nested types

* Move shared validation logic into collection/operations

* Show validation warning in log when loading some internal configs

* Show prettier actix JSON validation errors

* Stubs for pretty handling of query errors, reformat validation errors

* Use crate flatten function, the hard work was already done for us

We don't have to flatten validation errors into their qualified field
names ourselves because there is a utility function for this.

* Configure actix path validator

* Actix endpoints don't require public

* Extend validation to more actix types

* Validate all remaining actix path and query properties

* Rephrase range validation messages to clearly describe they're inclusive

* Validate all query params to respond with pretty deserialize errors

* Nicely format JSON payload deserialize error responses

* Improve error reporting for upsert point batches

* Add basic validation test that checks a path, query and payload value

* Add some validation constraints

* Add simple validation error render test

* Update Cargo.lock

---------

Co-authored-by: timvisee <tim+github@visee.me>
2023-04-03 09:43:55 +02:00