Skip to content
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

cloud_storage/ducktape: Wait for chunk observer to stop #14032

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions tests/rptest/tests/cloud_storage_chunk_read_path_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -369,6 +369,9 @@ def test_read_when_cache_smaller_than_segment_size(self):

self._consume_baseline(timeout=180, max_msgs=read_count)
observe_cache_dir.stop()
observe_cache_dir.join(timeout=10)
Copy link
Contributor

Choose a reason for hiding this comment

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

suggestion: this works, but it's a bit annoying to use. perhaps we could expose an interface a la with ObserveCacheDir(..) as observer: ...

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yeah, we can make it into a context manager, if we end up adding another call site for this utility I will add it (right now there is just one)

assert not observe_cache_dir.is_alive(
), 'cache observer is unexpectedly alive'

self._assert_not_in_cache(fr'.*kafka/{self.topic}/.*\.log\.[0-9]+$')
self._assert_in_cache(f'.*kafka/{self.topic}/.*_chunks/[0-9]+')
Expand Down
Loading