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

[5.0 -> main] Report snapshot rename location on failure #2178

Merged
merged 3 commits into from
Feb 1, 2024
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: 2 additions & 1 deletion libraries/chain/snapshot_scheduler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,8 @@ void snapshot_scheduler::create_snapshot(next_function<snapshot_information> nex
std::error_code ec;
fs::rename(temp_path, pending_path, ec);
EOS_ASSERT(!ec, snapshot_finalization_exception,
"Unable to promote temp snapshot to pending for block number ${bn}: [code: ${ec}] ${message}",
"Unable to promote temp snapshot ${t} to pending ${p} for block number ${bn}: [code: ${ec}] ${message}",
("t", temp_path.generic_string())("p", pending_path.generic_string())
("bn", head_block_num)("ec", ec.value())("message", ec.message()));
_pending_snapshot_index.emplace(head_id, next, pending_path.generic_string(), snapshot_path.generic_string());
add_pending_snapshot_info(snapshot_information{head_id, head_block_num, head_block_time, chain_snapshot_header::current_version, pending_path.generic_string()});
Expand Down
Loading