test/alternator: tests for vector index support
In this patch we add a large collection of basic functional tests for the vector index support, covering the CreateTable, UpdateTable, DescribeTable and Query operations and the various ways in which those are allowed to work - or expected to fail. These tests were written in parallel with writing the code so they (hopefully) cover all the corner cases considered during development, and make sure these corner cases are all handled correctly and will not regress in the future. Some of these tests do not involve querying of the index and focus on the structure of requests and the kind of syntax allowed. But other tests are end-to-end, requiring the vector store to be running and trying to index Alternator data and query it. These tests are marked "needs_vector_store", and are immediately skipped in Scylla is not configured to connect to a vector store. In a later patch we'll add a an option to test/alternator/run to be able to run these end-to-end tests by automatically running both Scylla and the Vector Store. We'll have additional end-to-end tests in the vector-store repository. Note that vector search is a new API feature that doesn't exist in DynamoDB, so we are adding new parameters and outputs to existing operations. The AWS SDKs don't normally allow doing that, so the test added here begins by teaching the Python SDK to use the new APIs we added. This piece of code can also be used by end-users to use vector search (at least in Python...) before we officially add this support to ScyllaDB's SDK wrappers.
This commit is contained in:
2208
test/alternator/test_vector.py
Normal file
2208
test/alternator/test_vector.py
Normal file
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user