Skip to content

validator: add Alternator index creation test#452

Merged
ewienik merged 1 commit into
scylladb:masterfrom
m-szymon:alternator_tests_part1
May 20, 2026
Merged

validator: add Alternator index creation test#452
ewienik merged 1 commit into
scylladb:masterfrom
m-szymon:alternator_tests_part1

Conversation

@m-szymon

Copy link
Copy Markdown
Collaborator

Introduce the Alternator integration test suite with shared infrastructure (TableShape, Naming patterns, Injectors for customized AWS SDK calls) and test for basic table and index lifecycle operations: CreateTable, DescribeTable, DeleteTable.

@m-szymon
m-szymon force-pushed the alternator_tests_part1 branch 2 times, most recently from 517fb7c to 7e14300 Compare May 18, 2026 08:21
@m-szymon
m-szymon marked this pull request as ready for review May 18, 2026 08:36
@m-szymon
m-szymon requested review from QuerthDP and ewienik May 18, 2026 08:36
@m-szymon

Copy link
Copy Markdown
Collaborator Author

As requested I am splitting #392 into smaller commits.

@m-szymon
m-szymon force-pushed the alternator_tests_part1 branch from 7e14300 to 52fffc0 Compare May 18, 2026 08:55
ewienik
ewienik previously approved these changes May 18, 2026

@ewienik ewienik left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

LGTM, thanks for dividing previous huge PR.

@QuerthDP do you have more comments

Comment thread crates/validator/src/common.rs Outdated
Introduce the Alternator integration test suite with shared infrastructure
(TableShape, Naming patterns, Injectors for customized AWS SDK calls)
and test for basic table and index lifecycle operations:
CreateTable, DescribeTable, DeleteTable.
@ewienik
ewienik added this pull request to the merge queue May 20, 2026

@QuerthDP QuerthDP left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Looks good.
Feel free to resolve my comments without any changes if you don't believe they're relevant.
It can be merged as is.

use tracing::info;

/// An SDK interceptor that captures the `VectorIndexes` extension field from
/// the raw `DescribeTable` JSON response as a [`serde_json::Value`]. The

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

nit: double space

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Fixed in next PR.

Comment on lines +103 to +113
/// ```ignore
/// client
/// .create_table()
/// // ...
/// .customize()
/// .interceptor(JsonBodyInjectInterceptor::new([
/// ("VectorIndexes", vector_indexes_json),
/// ]))
/// .send()
/// .await?;
/// ```

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Let's not add ignored code in docstrings. Either make it work or remove

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

I think illustrative example is justified here.

Comment on lines +217 to +227
async fn wait_for_index(clients: &[HttpClient], index: &IndexInfo) {
for client in clients {
common::wait_for_index(client, index).await;
}
}

async fn wait_for_no_index(clients: &[HttpClient], index: &IndexInfo) {
for client in clients {
common::wait_for_no_index(client, index).await;
}
}

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

This could be in common.rs as well

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Could be, but under different name.
Or refactor all tests to wait for all clients they have (unless we want explicitly a subarray). Waiting for single client is potentially flaky.

Merged via the queue into scylladb:master with commit c3990b8 May 20, 2026
27 checks passed
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.

3 participants