From ccfccee77bf590190c509ac05c41bb11ee22bb17 Mon Sep 17 00:00:00 2001 From: JiahuaChen Date: Thu, 8 Feb 2024 02:26:43 +0000 Subject: [PATCH] Change code owners --- .../allocator/ob_fixed_size_block_allocator.h | 1 - .../storage/blocksstable/test_cg_sstable.cpp | 18 ++++++++---- .../storage/blocksstable/test_index_tree.cpp | 3 +- .../inner_table/ob_inner_table_schema_def.py | 10 +++---- .../index_block/ob_agg_row_struct.cpp | 28 ++++++++++--------- .../index_block/ob_index_block_builder.cpp | 5 +--- .../blocksstable/ob_macro_block_writer.cpp | 3 +- .../ob_shared_block_reader_writer.cpp | 6 ++-- src/storage/meta_mem/ob_meta_obj_struct.h | 1 - .../meta_mem/ob_storage_meta_cache.cpp | 2 +- src/storage/meta_mem/ob_tablet_pointer.cpp | 2 +- src/storage/tablet/ob_full_tablet_creator.cpp | 1 - .../blocksstable/test_agg_row_struct.cpp | 1 - 13 files changed, 40 insertions(+), 41 deletions(-) diff --git a/deps/oblib/src/lib/allocator/ob_fixed_size_block_allocator.h b/deps/oblib/src/lib/allocator/ob_fixed_size_block_allocator.h index 6e5e607010..bee6f09484 100644 --- a/deps/oblib/src/lib/allocator/ob_fixed_size_block_allocator.h +++ b/deps/oblib/src/lib/allocator/ob_fixed_size_block_allocator.h @@ -64,7 +64,6 @@ public: static const int64_t MAX_MEMORY_ALLOCATION = OB_MAX_SYS_BKGD_THREAD_NUM * 2 * OB_DEFAULT_MACRO_BLOCK_SIZE; //256MB private: - // TODO(zhuixin.gsy) reduce 128*2M size to 64*2M, which is expanded temporarily for generating index blocks static const int64_t MAX_MEMORY_IN_MINI_MODE = 64 * OB_DEFAULT_MACRO_BLOCK_SIZE; //128MB bool is_inited_; diff --git a/mittest/mtlenv/storage/blocksstable/test_cg_sstable.cpp b/mittest/mtlenv/storage/blocksstable/test_cg_sstable.cpp index bf22cd40f2..da51b20ccd 100644 --- a/mittest/mtlenv/storage/blocksstable/test_cg_sstable.cpp +++ b/mittest/mtlenv/storage/blocksstable/test_cg_sstable.cpp @@ -1,3 +1,15 @@ +/** + * Copyright (c) 2023 OceanBase + * OceanBase CE is licensed under Mulan PubL v2. + * You can use this software according to the terms and conditions of the Mulan PubL v2. + * You may obtain a copy of Mulan PubL v2 at: + * http://license.coscl.org.cn/MulanPubL-2.0 + * THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND, + * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT, + * MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE. + * See the Mulan PubL v2 for more details. + */ + #include #define private public #define protected public @@ -144,12 +156,6 @@ TEST_F(TestCgSSTable, test_cg_index_tree_cursor) cg_rowkey[0].set_int(i); OK(tree_cursor.pull_up_to_root()); OK(tree_cursor.drill_down(rowkey, ObIndexBlockTreeCursor::MoveDepth::LEAF, true, equal, is_beyond_range)); - // { - // STORAGE_LOG(INFO, "zhuixin debug", K(i), KPC(tree_cursor.curr_path_item_)); - // OK(tree_cursor.get_idx_parser(parser)); - // OK(tree_cursor.get_current_endkey(endkey)); - // STORAGE_LOG(INFO, "zhuixin debug", KPC(parser), K(endkey), K(is_beyond_range)); - // } ASSERT_FALSE(is_beyond_range); if (is_macro_start) { OK(tree_cursor.get_current_endkey(endkey)); diff --git a/mittest/mtlenv/storage/blocksstable/test_index_tree.cpp b/mittest/mtlenv/storage/blocksstable/test_index_tree.cpp index 8db60687f6..2a68eecca6 100644 --- a/mittest/mtlenv/storage/blocksstable/test_index_tree.cpp +++ b/mittest/mtlenv/storage/blocksstable/test_index_tree.cpp @@ -1296,7 +1296,7 @@ TEST_F(TestIndexTree, test_reuse_macro_block) TEST_F(TestIndexTree, DISABLED_test_writer_try_to_append_row) { - // TODO(zhuixin.gsy) fix try_to_append_row, enable this case + // fix try_to_append_row, enable this case int ret = OB_SUCCESS; ObDatumRow row; OK(row.init(allocator_, TEST_COLUMN_CNT)); @@ -1320,7 +1320,6 @@ TEST_F(TestIndexTree, DISABLED_test_writer_try_to_append_row) } OK(micro_writer->build_micro_block_desc(micro_block_desc)); const int64_t need_store_size = micro_block_desc.buf_size_ + micro_block_desc.header_->header_size_; - STORAGE_LOG(INFO, "zhuixin debug block", K(micro_block_desc)); { // set size upper bound after reuse micro_writer->reuse(); diff --git a/src/share/inner_table/ob_inner_table_schema_def.py b/src/share/inner_table/ob_inner_table_schema_def.py index 91479f858e..8cc5641927 100644 --- a/src/share/inner_table/ob_inner_table_schema_def.py +++ b/src/share/inner_table/ob_inner_table_schema_def.py @@ -9913,7 +9913,7 @@ def_table_schema( ) def_table_schema( - owner = 'zhuixin.gsy', + owner = 'luhaopeng.lhp', table_name = '__all_virtual_table_mgr', table_id = '12034', table_type = 'VIRTUAL_TABLE', @@ -16834,7 +16834,7 @@ WHERE SVR_IP=HOST_IP() AND SVR_PORT=RPC_PORT() ) def_table_schema( -owner = 'zhuixin.gsy', +owner = 'luhaopeng.lhp', table_name = 'GV$OB_SSTABLES', table_id = '21100', table_type = 'SYSTEM_VIEW', @@ -16872,7 +16872,7 @@ FROM ) def_table_schema( -owner = 'zhuixin.gsy', +owner = 'luhaopeng.lhp', table_name = 'V$OB_SSTABLES', table_id = '21101', table_type = 'SYSTEM_VIEW', @@ -51877,7 +51877,7 @@ def_table_schema( ) def_table_schema( -owner = 'zhuixin.gsy', +owner = 'luhaopeng.lhp', table_name = 'GV$OB_SSTABLES', name_postfix = '_ORA', database_id = 'OB_ORA_SYS_DATABASE_ID', @@ -51913,7 +51913,7 @@ FROM ) def_table_schema( -owner = 'zhuixin.gsy', +owner = 'luhaopeng.lhp', table_name = 'V$OB_SSTABLES', name_postfix = '_ORA', database_id = 'OB_ORA_SYS_DATABASE_ID', diff --git a/src/storage/blocksstable/index_block/ob_agg_row_struct.cpp b/src/storage/blocksstable/index_block/ob_agg_row_struct.cpp index f99aaa8cbc..64d20c14bd 100644 --- a/src/storage/blocksstable/index_block/ob_agg_row_struct.cpp +++ b/src/storage/blocksstable/index_block/ob_agg_row_struct.cpp @@ -1,12 +1,14 @@ -// Copyright (c) 2021 Ant Group CO., Ltd. -// OceanBase is licensed under Mulan PubL v1. -// You can use this software according to the terms and conditions of the Mulan PubL v1. -// You may obtain a copy of Mulan PubL v1 at: -// http://license.coscl.org.cn/MulanPubL-1.0 -// THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND, -// EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT, -// MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE. -// See the Mulan PubL v1 for more details. +/** + * Copyright (c) 2023 OceanBase + * OceanBase CE is licensed under Mulan PubL v2. + * You can use this software according to the terms and conditions of the Mulan PubL v2. + * You may obtain a copy of Mulan PubL v2 at: + * http://license.coscl.org.cn/MulanPubL-2.0 + * THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND, + * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT, + * MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE. + * See the Mulan PubL v2 for more details. + */ #define USING_LOG_PREFIX STORAGE #include "storage/blocksstable/index_block/ob_agg_row_struct.h" @@ -83,7 +85,7 @@ int ObAggRowWriter::sort_metas(const ObIArray &agg_col_arr, } std::sort(col_meta_list_.begin(), col_meta_list_.end()); for (int64_t i = 0; OB_SUCC(ret) && i < column_count_; ++i) { - LOG_DEBUG("zhuixin debug sort", K(i), K(col_meta_list_.at(i).first), K(col_meta_list_.at(i).second)); + LOG_DEBUG("sort", K(i), K(col_meta_list_.at(i).first), K(col_meta_list_.at(i).second)); } } return ret; @@ -195,13 +197,13 @@ int ObAggRowWriter::write_cell( } else { col_off_arr.set(idx, pos - orig_pos); MEMCPY(buf + pos, datum.ptr_, datum.len_); // copy data - LOG_DEBUG("zhuixin debug write cell", K(idx), K(datum), K(pos), K(val), K(start), K(end)); + LOG_DEBUG("write cell", K(idx), K(datum), K(pos), K(val), K(start), K(end)); pos += datum.len_; } ++idx; } if (OB_SUCC(ret) && stored_col_cnt > 0) { - LOG_DEBUG("zhuixin debug write cell(reserved)", K(idx), K(pos), K(orig_pos), K(header_size_)); + LOG_DEBUG("write cell(reserved)", K(idx), K(pos), K(orig_pos), K(header_size_)); col_off_arr.set(stored_col_cnt - 1, pos - orig_pos); // cell end } } @@ -432,7 +434,7 @@ int ObAggRowReader::read_cell( } col_off = col_off_arr.at(pre_cnt); col_len = col_off_arr.at(pre_cnt + 1) - col_off; - LOG_DEBUG("zhuixin debug read cell", K(ret), K(pre_cnt), K(col_off), K(col_len)); + LOG_DEBUG("read cell", K(ret), K(pre_cnt), K(col_off), K(col_len)); } return ret; } diff --git a/src/storage/blocksstable/index_block/ob_index_block_builder.cpp b/src/storage/blocksstable/index_block/ob_index_block_builder.cpp index 0f3af9ae16..1113161747 100644 --- a/src/storage/blocksstable/index_block/ob_index_block_builder.cpp +++ b/src/storage/blocksstable/index_block/ob_index_block_builder.cpp @@ -438,7 +438,7 @@ void ObSSTableIndexBuilder::reset() bool ObSSTableIndexBuilder::check_index_desc(const ObDataStoreDesc &index_desc) const { bool ret = true; - // TODO(zhuixin.gsy): these args influence write_micro_block and need to be evaluated + // these args influence write_micro_block and need to be evaluated if (!index_desc.is_valid() || index_desc.merge_info_ != nullptr || index_desc.get_row_column_count() != index_desc.get_rowkey_column_count() + 1 @@ -644,7 +644,6 @@ int ObSSTableIndexBuilder::trim_empty_roots() } int ObSSTableIndexBuilder::ObMacroMetaIter::init(IndexTreeRootCtxList &roots, const bool is_cg) { - // TODO(zhuixin.gsy) reserve roots_ int ret = OB_SUCCESS; if (IS_INIT) { ret = OB_INIT_TWICE; @@ -1523,7 +1522,6 @@ int ObBaseIndexBlockBuilder::close_index_tree(ObBaseIndexBlockBuilder *&root_bui } else if (OB_UNLIKELY(next_level_builder_ == nullptr)) { root_builder = this; } else { - //TODO(zhuixin.gsy) check if row_count == 0 is error? if (OB_LIKELY(micro_writer_->get_row_count() > 0)) { if (OB_FAIL(append_index_micro_block())) { STORAGE_LOG(WARN, "Fail to append index micro block, ", K(ret)); @@ -1847,7 +1845,6 @@ int ObDataIndexBlockBuilder::insert_and_update_index_tree(const ObDatumRow *inde int ObDataIndexBlockBuilder::cal_macro_meta_block_size( const ObDatumRowkey &rowkey, int64_t &estimate_meta_block_size) { - // TODO(zhuixin.gsy) fix and add agg_row_buf_ max size int ret = OB_SUCCESS; ObDataMacroBlockMeta macro_meta; const int64_t rowkey_cnt = rowkey.datum_cnt_; diff --git a/src/storage/blocksstable/ob_macro_block_writer.cpp b/src/storage/blocksstable/ob_macro_block_writer.cpp index 5c3c248e0f..7a88b0849c 100644 --- a/src/storage/blocksstable/ob_macro_block_writer.cpp +++ b/src/storage/blocksstable/ob_macro_block_writer.cpp @@ -1294,7 +1294,6 @@ int ObMacroBlockWriter::write_micro_block(ObMicroBlockDesc µ_block_desc) } } - // TODO(zhuixin.gsy): ensure bloomfilter correct for index micro block if (OB_SUCC(ret)) { last_micro_size_ = micro_block_desc.data_size_; last_micro_expand_pct_ = micro_block_desc.original_size_ * 100 / micro_block_desc.data_size_; @@ -1343,7 +1342,7 @@ int ObMacroBlockWriter::try_active_flush_macro_block() int ObMacroBlockWriter::flush_macro_block(ObMacroBlock ¯o_block) { int ret = OB_SUCCESS; - ObLogicMacroBlockId cur_logic_id; // TODO(zhuixin.gsy) rm this if DDL Rebuild Ready + ObLogicMacroBlockId cur_logic_id; cur_logic_id.logic_version_ = data_store_desc_->get_logical_version(); cur_logic_id.column_group_idx_ = data_store_desc_->get_table_cg_idx(); cur_logic_id.data_seq_.macro_data_seq_ = current_macro_seq_; diff --git a/src/storage/blockstore/ob_shared_block_reader_writer.cpp b/src/storage/blockstore/ob_shared_block_reader_writer.cpp index 32483644f0..8d33619e93 100644 --- a/src/storage/blockstore/ob_shared_block_reader_writer.cpp +++ b/src/storage/blockstore/ob_shared_block_reader_writer.cpp @@ -372,7 +372,7 @@ int ObSharedBlockReadHandle::verify_checksum( header_size = header->header_size_; buf_len = header->data_size_; } - LOG_DEBUG("zhuixin debug read shared block", K(ret), KPC(header)); + LOG_DEBUG("read shared block", K(ret), KPC(header)); } return ret; } @@ -552,7 +552,7 @@ int ObSharedBlockLinkIter::read_next_block(ObSharedBlockReadHandle &block_handle const ObSharedBlockHeader *header = reinterpret_cast(macro_handle.get_buffer()); cur_ = header->prev_addr_; - LOG_DEBUG("zhuixin debug get next link block", K(ret), K(head_), K(cur_), KPC(header)); + LOG_DEBUG("get next link block", K(ret), K(head_), K(cur_), KPC(header)); } return ret; } @@ -926,7 +926,7 @@ int ObSharedBlockReaderWriter::inner_write_block( } else if (!need_flush) { hanging_ = true; } - LOG_DEBUG("zhuixin debug inner write block", K(ret), K(header), K(size), K(need_flush), + LOG_DEBUG("inner write block", K(ret), K(header), K(size), K(need_flush), K(need_align), K(store_size), K(align_store_size), K(offset_), K(align_offset_), K(hanging_), K(addr), K(macro_handle)); } diff --git a/src/storage/meta_mem/ob_meta_obj_struct.h b/src/storage/meta_mem/ob_meta_obj_struct.h index 297f4c8bbf..6b91bd15ee 100644 --- a/src/storage/meta_mem/ob_meta_obj_struct.h +++ b/src/storage/meta_mem/ob_meta_obj_struct.h @@ -172,7 +172,6 @@ protected: virtual void reset_obj(); protected: - // TODO(zhuixin.gsy) rm *obj_pool_ and *allocator_ T *obj_; ObITenantMetaObjPool *obj_pool_; common::ObIAllocator *allocator_; diff --git a/src/storage/meta_mem/ob_storage_meta_cache.cpp b/src/storage/meta_mem/ob_storage_meta_cache.cpp index 5080ee915a..17dda5ca42 100644 --- a/src/storage/meta_mem/ob_storage_meta_cache.cpp +++ b/src/storage/meta_mem/ob_storage_meta_cache.cpp @@ -758,7 +758,7 @@ int ObStorageMetaCache::batch_get_meta_and_bypass_cache( ret = OB_INVALID_ARGUMENT; LOG_WARN("invalid arguments", K(ret), K(meta_types), K(keys)); } else { - // TODO: @zhuixin implement batch read in shared block reader. + // TODO: implement batch read in shared block reader. for (int64_t i = 0; OB_SUCC(ret) && i < keys.count(); ++i) { const ObStorageMetaValue::MetaType &meta_type = meta_types.at(i); const ObStorageMetaKey &key = keys.at(i); diff --git a/src/storage/meta_mem/ob_tablet_pointer.cpp b/src/storage/meta_mem/ob_tablet_pointer.cpp index f5244d1160..fbb76da315 100644 --- a/src/storage/meta_mem/ob_tablet_pointer.cpp +++ b/src/storage/meta_mem/ob_tablet_pointer.cpp @@ -686,7 +686,7 @@ ObITabletFilterOp::~ObITabletFilterOp() total_tablet_cnt_ += total_cnt_; not_in_mem_tablet_cnt_ += not_in_mem_cnt_; invalid_attr_tablet_cnt_ += invalid_attr_cnt_; - LOG_INFO("zhuixin debug filter destructed", + LOG_INFO("tablet skip filter destructed", K_(total_cnt), K_(skip_cnt), K_(not_in_mem_cnt), K_(invalid_attr_cnt), K_(total_tablet_cnt), K_(total_skip_cnt), K_(not_in_mem_tablet_cnt), K_(invalid_attr_tablet_cnt)); } diff --git a/src/storage/tablet/ob_full_tablet_creator.cpp b/src/storage/tablet/ob_full_tablet_creator.cpp index 5df40d75de..45ce869829 100644 --- a/src/storage/tablet/ob_full_tablet_creator.cpp +++ b/src/storage/tablet/ob_full_tablet_creator.cpp @@ -136,7 +136,6 @@ int ObFullTabletCreator::create_tablet(ObTabletHandle &tablet_handle) ObArenaAllocator, (&tiny_allocator_), mstx_mem_ctx_->get_malloc_allocator(), page_size))) { ret = OB_ALLOCATE_MEMORY_FAILED; LOG_WARN("fail to new arena allocator", K(ret)); - /* TODO(zhuixin.gsy) rm these set_xx after merge master*/ } else if (FALSE_IT(allocator->set_label("MSTXAllocator"))) { } else if (FALSE_IT(allocator->set_tenant_id(MTL_ID()))) { } else if (FALSE_IT(allocator->set_ctx_id(ObCtxIds::DEFAULT_CTX_ID))) { diff --git a/unittest/storage/blocksstable/test_agg_row_struct.cpp b/unittest/storage/blocksstable/test_agg_row_struct.cpp index 4897ee23e0..d413320a38 100644 --- a/unittest/storage/blocksstable/test_agg_row_struct.cpp +++ b/unittest/storage/blocksstable/test_agg_row_struct.cpp @@ -80,7 +80,6 @@ TEST_F(TestAggRow, test_agg_row) agg_row.storage_datums_[cnt].set_int(cnt); } OK(is_null.push_back(null)); - STORAGE_LOG(INFO, "zhuixin debug", K(cnt), K(col_meta), K(null)); has[col_idx][col_type] = true; ++cnt; }