-
Notifications
You must be signed in to change notification settings - Fork 714
cloud_storage/tests: use better containers in s3_imposter #29512
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -244,7 +244,7 @@ class async_manifest_view_fixture | |
| } | ||
| } | ||
|
|
||
| void listen() { set_expectations_and_listen(_expectations); } | ||
| void listen() { set_expectations_and_listen(std::move(_expectations)); } | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. this ok? just happens once and then no more uses of expectations member var?
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yea, this is only used to set up expectations at the beginning of certain tests |
||
|
|
||
| void collect_segments_to(std::vector<segment_meta>& meta) { | ||
| all_segments = std::ref(meta); | ||
|
|
@@ -330,7 +330,7 @@ class async_manifest_view_fixture | |
| retry_chain_logger ctxlog; | ||
| partition_probe probe; | ||
| async_manifest_view view; | ||
| std::vector<expectation> _expectations; | ||
| chunked_vector<expectation> _expectations; | ||
| std::vector<model::offset> spillover_start_offsets; | ||
| model::offset _last_spillover_offset; | ||
| std::optional<std::reference_wrapper<std::vector<segment_meta>>> | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The reserve() call was removed when converting from std::vector to chunked_vector. While chunked_vector has different memory characteristics, pre-allocating capacity when the upper bound is known (_requests.size()) could still improve performance by reducing reallocations.