add more logs
Summary: as subject Test Plan:db_test Reviewers: dhruba
This commit is contained in:
parent
5d96f290b3
commit
1c99b0a6b3
@ -285,7 +285,12 @@ void DBImpl::DeleteObsoleteFiles() {
|
||||
Log(options_.info_log, "Delete type=%d #%lld\n",
|
||||
int(type),
|
||||
static_cast<unsigned long long>(number));
|
||||
env_->DeleteFile(dbname_ + "/" + filenames[i]);
|
||||
Status st = env_->DeleteFile(dbname_ + "/" + filenames[i]);
|
||||
if(!st.ok()) {
|
||||
Log(options_.info_log, "Delete type=%d #%lld FAILED\n",
|
||||
int(type),
|
||||
static_cast<unsigned long long>(number));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -844,6 +844,9 @@ Status VersionSet::Recover() {
|
||||
}
|
||||
current.resize(current.size() - 1);
|
||||
|
||||
Log(options_->info_log, "Recovering from manifest file:%s\n",
|
||||
current.c_str());
|
||||
|
||||
std::string dscname = dbname_ + "/" + current;
|
||||
SequentialFile* file;
|
||||
s = env_->NewSequentialFile(dscname, &file);
|
||||
@ -935,6 +938,13 @@ Status VersionSet::Recover() {
|
||||
last_sequence_ = last_sequence;
|
||||
log_number_ = log_number;
|
||||
prev_log_number_ = prev_log_number;
|
||||
|
||||
Log(options_->info_log, "Recovering from manifest file:%s succeeded,"
|
||||
"manifest_file_number is %lld, next_file_number is %lld, "
|
||||
"last_sequence is %lld, log_number is %lld,"
|
||||
"prev_log_number is %lld\n",
|
||||
current.c_str(), manifest_file_number_, next_file_number_,
|
||||
last_sequence_, log_number_, prev_log_number_);
|
||||
}
|
||||
|
||||
return s;
|
||||
|
Loading…
Reference in New Issue
Block a user