[FEAT MERGE] 4.2 add trans_debug_info for 4377

Co-authored-by: Handora <qcdsr970209@gmail.com>
This commit is contained in:
yishenglanlingzui
2023-05-06 06:08:35 +00:00
committed by ob-robot
parent 711f4d5cd0
commit 9e328378c8
63 changed files with 1013 additions and 169 deletions

View File

@ -196,7 +196,8 @@ ObDatumRow::ObDatumRow()
storage_datums_(nullptr),
datum_buffer_(),
old_row_(),
obj_buf_()
obj_buf_(),
trans_info_(nullptr)
{}
ObDatumRow::~ObDatumRow()
@ -204,7 +205,7 @@ ObDatumRow::~ObDatumRow()
reset();
}
int ObDatumRow::init(ObIAllocator &allocator, const int64_t capacity)
int ObDatumRow::init(ObIAllocator &allocator, const int64_t capacity, char *trans_info_ptr)
{
int ret = OB_SUCCESS;
if (OB_UNLIKELY(is_valid())) {
@ -219,9 +220,11 @@ int ObDatumRow::init(ObIAllocator &allocator, const int64_t capacity)
} else {
storage_datums_ = datum_buffer_.get_datums();
count_ = capacity;
// trans_info_ptr maybe is nullptr,
// ObDatumRow does not care about the free of trans_info_ptr's memory
trans_info_ = trans_info_ptr;
}
return ret;
}
int ObDatumRow::init(const int64_t capacity)
@ -310,6 +313,7 @@ void ObDatumRow::reset()
row_flag_.reset();
count_ = 0;
local_allocator_.reset();
trans_info_ = nullptr;
}
void ObDatumRow::reuse()
@ -326,6 +330,9 @@ void ObDatumRow::reuse()
snapshot_version_ = 0;
fast_filter_skipped_ = false;
have_uncommited_row_ = false;
if (OB_NOT_NULL(trans_info_)) {
trans_info_[0] = '\0';
}
}
int ObDatumRow::deep_copy(const ObDatumRow &src, ObIAllocator &allocator)