Patch some commits to open source branch

This commit is contained in:
rl0
2021-07-22 00:31:09 +08:00
committed by wangzelin.wzl
parent 69fa727d91
commit 5839aec035
30 changed files with 2827 additions and 291 deletions

View File

@ -150,7 +150,7 @@ int ObCLogWriter::set_is_disk_error()
ret = OB_NOT_INIT;
} else {
ATOMIC_STORE(&is_disk_error_, true);
CLOG_LOG(ERROR, "clog disk is error!!!");
CLOG_LOG(WARN, "clog disk may be hang or something error has happen!");
}
return ret;
}
@ -162,7 +162,7 @@ int ObCLogWriter::reset_is_disk_error()
ret = OB_NOT_INIT;
} else {
ATOMIC_STORE(&is_disk_error_, false);
CLOG_LOG(INFO, "reset clog disk status to normal");
CLOG_LOG(TRACE, "reset clog disk status to normal");
}
return ret;
}
@ -204,12 +204,12 @@ void ObCLogWriter::process_log_items(common::ObIBaseLogItem** items, const int64
} else {
const bool is_idempotent = false;
const uint64_t write_len = block_meta_len + item->get_data_len();
const int64_t warning_value = GCONF.data_storage_warning_tolerance_time;
ObCLogDiskErrorCB *cb = NULL;
lib::ObMutexGuard guard(file_mutex_);
BG_NEW_CALLBACK(cb, ObCLogDiskErrorCB, this);
BG_MONITOR_GUARD(DEFAULT_CLOG_FLUSH_TIMEOUT_US, is_idempotent, cb);
BG_MONITOR_GUARD(warning_value, is_idempotent, cb);
// The timestamp value in block header must be generated by the time order, so
// call inner_switch_file first here.
@ -378,7 +378,8 @@ ObCLogDiskErrorCB::ObCLogDiskErrorCB(ObCLogWriter* host) : host_(host)
{}
ObCLogDiskErrorCB::~ObCLogDiskErrorCB()
{}
{
}
int ObCLogDiskErrorCB::callback()
{
@ -404,8 +405,11 @@ void ObCLogDiskErrorCB::destroy()
}
}
int locate_clog_tail(
const int64_t timeout, ObILogFileStore* file_store, ObLogDirectReader* reader, file_id_t& file_id, offset_t& offset)
int locate_clog_tail(const int64_t timeout,
ObILogFileStore *file_store,
ObLogDirectReader *reader,
file_id_t &file_id,
offset_t &offset)
{
ObLogFileTailLocatorImpl<ObLogEntry, ObIRawLogIterator> impl;
return impl.locate_tail(timeout, file_store, reader, file_id, offset);