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

RandomNodeOperation test improvements and fixes #15032

Merged
merged 3 commits into from
Nov 21, 2023
Merged
Show file tree
Hide file tree
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
2 changes: 1 addition & 1 deletion src/v/cloud_storage/partition_manifest.cc
Original file line number Diff line number Diff line change
Expand Up @@ -744,7 +744,7 @@ void partition_manifest::set_archive_clean_offset(

bool partition_manifest::advance_start_kafka_offset(
kafka::offset new_start_offset) {
if (_start_kafka_offset_override >= new_start_offset) {
if (_start_kafka_offset_override > new_start_offset) {
return false;
}
_start_kafka_offset_override = new_start_offset;
Expand Down
4 changes: 2 additions & 2 deletions src/v/cloud_storage/tests/partition_manifest_test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1431,9 +1431,9 @@ SEASTAR_THREAD_TEST_CASE(test_partition_manifest_start_kafka_offset_advance) {
m.get_start_kafka_offset_override(), kafka::offset(370));
BOOST_REQUIRE_EQUAL(m.get_start_offset(), model::offset(100));
BOOST_REQUIRE_EQUAL(m.get_start_kafka_offset(), kafka::offset(90));

// Allow update with the same value
BOOST_REQUIRE(m.advance_start_kafka_offset(kafka::offset(370)));
// If trying to move back, it should no-op.
BOOST_REQUIRE(!m.advance_start_kafka_offset(kafka::offset(370)));
BOOST_REQUIRE(!m.advance_start_kafka_offset(kafka::offset(369)));
BOOST_REQUIRE_EQUAL(
m.get_start_kafka_offset_override(), kafka::offset(370));
Expand Down
5 changes: 4 additions & 1 deletion src/v/raft/state_machine_manager.cc
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,10 @@ ss::future<> state_machine_manager::apply_raft_snapshot() {
co_await snapshot->reader.close();
if (fut.failed()) {
const auto e = fut.get_exception();
vlog(_log.error, "error applying raft snapshot - {}", e);
// do not log known shutdown exceptions as errors
if (!ssx::is_shutdown_exception(e)) {
vlog(_log.error, "error applying raft snapshot - {}", e);
}
std::rethrow_exception(e);
}
}
Expand Down
6 changes: 4 additions & 2 deletions tests/rptest/tests/random_node_operations_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,11 @@
from rptest.clients.offline_log_viewer import OfflineLogViewer

TS_LOG_ALLOW_LIST = [
re.compile("archival_stm.*Replication wait for archival STM timed out"),
re.compile(
".*archival_metadata_stm.*Replication wait for archival STM timed out"
),
# topic deletion may happen before data were uploaded
re.compile("cloud_storage.*Failed to fetch manifest during finalize().*")
re.compile(".*cloud_storage.*Failed to fetch manifest during finalize().*")
]


Expand Down