提交 fd0fb243 编写于 作者: S simonjoylet 提交者: LINGuanRen

fix compile and dump sstable_meta of ob_admin

上级 a22496d9
......@@ -22,7 +22,6 @@
#include "share/backup/ob_tenant_name_mgr.h"
#include "storage/blocksstable/ob_block_sstable_struct.h"
#include "storage/blocksstable/ob_macro_block_meta_mgr.h"
#include "storage/blocksstable/ob_store_file.h"
#include "storage/ob_i_table.h"
#include "observer/ob_server_struct.h"
......
......@@ -15,9 +15,7 @@
#include "storage/blocksstable/ob_store_file.h"
#include "storage/ob_partition_service.h"
#include "storage/ob_table_mgr.h"
#include "storage/ob_table_mgr_meta_block_reader.h"
#include "storage/ob_sstable.h"
#include "storage/blocksstable/ob_macro_meta_block_reader.h"
#include "storage/ob_tenant_config_mgr.h"
#include "storage/ob_tenant_config_meta_block_reader.h"
#include "storage/blocksstable/ob_micro_block_scanner.h"
......@@ -360,14 +358,7 @@ void ObAdminDumpsstExecutor::print_macro_meta()
{
// int ret = OB_SUCCESS;
const ObMacroBlockMeta *meta = NULL;
ObMacroBlockMetaHandle meta_handle;
MacroBlockId macro_id(dump_macro_context_.macro_id_);
/*if (OB_FAIL(ObMacroBlockMetaMgr::get_instance().get_meta(macro_id, meta_handle))) {
STORAGE_LOG(ERROR, "failed to get meta", K(ret));
} else if (OB_ISNULL(meta = meta_handle.get_meta())) {
ret = OB_ERR_UNEXPECTED;
STORAGE_LOG(ERROR, "meta is null", K(ret));
} else {*/
PrintHelper::print_dump_title("Macro Meta");
PrintHelper::print_dump_line("macro_block_id", dump_macro_context_.macro_id_);
PrintHelper::print_dump_line("attr", meta->attr_);
......@@ -417,7 +408,6 @@ void ObAdminDumpsstExecutor::print_macro_meta()
}
PrintHelper::print_dump_list_end();
PrintHelper::print_end_line();
//}
}
void ObAdminDumpsstExecutor::dump_sstable()
......@@ -456,12 +446,9 @@ void ObAdminDumpsstExecutor::dump_sstable()
void ObAdminDumpsstExecutor::dump_sstable_meta()
{
int ret = OB_SUCCESS;
ObTableHandle handle;
ObSSTable *sstable = NULL;
if (OB_FAIL(ObPartitionService::get_instance().acquire_sstable(table_key_, handle))) {
if (OB_FAIL(replay_slog_to_get_sstable(sstable))) {
STORAGE_LOG(ERROR, "fail to acquire table", K(ret), K(table_key_));
} else if (OB_FAIL(handle.get_sstable(sstable))) {
STORAGE_LOG(ERROR, "fail to get sstable", K(ret));
} else if (OB_ISNULL(sstable)) {
ret = OB_ERR_UNEXPECTED;
STORAGE_LOG(WARN, "error unexpected, sstable must not be NULL", K(ret));
......
......@@ -16,7 +16,6 @@
#include "lib/container/ob_array.h"
#include "share/config/ob_config_manager.h"
#include "storage/blocksstable/ob_block_sstable_struct.h"
#include "storage/blocksstable/ob_macro_block_meta_mgr.h"
#include "storage/blocksstable/ob_store_file.h"
#include "storage/ob_i_table.h"
#include "observer/ob_server_struct.h"
......
......@@ -13,7 +13,6 @@
#define USING_LOG_PREFIX COMMON
#include "ob_admin_slog_executor.h"
#include "storage/blocksstable/slog/ob_base_storage_logger.h"
#include "storage/blocksstable/ob_macro_block_meta_mgr.h"
#include "storage/ob_partition_service.h"
#include "storage/ob_table_mgr.h"
#include "storage/ob_tenant_config_mgr.h"
......@@ -49,9 +48,6 @@ int ObAdminSlogExecutor::execute(int argc, char *argv[])
if (NULL != log_dir_ && log_file_id_ > 0) {
if (OB_FAIL(SLOGGER.register_redo_module(OB_REDO_LOG_PARTITION, &partition_module))) {
LOG_WARN("fail to register partition module", K(ret));
} else if (OB_FAIL(SLOGGER.register_redo_module(OB_REDO_LOG_MACROBLOCK,
&ObMacroBlockMetaMgr::get_instance()))) {
LOG_WARN("fail to register macro module", K(ret));
} else if (OB_FAIL(SLOGGER.register_redo_module(OB_REDO_LOG_TABLE_MGR,
&ObTableMgr::get_instance()))) {
LOG_WARN("fail to register table module", K(ret));
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册